But if you're a programmer without a scientific speciality, then there's less reason.
The contractors have some freedom to pay as they see fit -- they pay more than the national labs in my experience -- but they still have to justify their rates to the government during contract negotiations, and the government can push back. The pay is "ok", but has been falling increasingly behind "Tech". So now there's brain drain, particularly among programmers.
My impression is that if you do work directly for federal or state government, you also are likely to be alongside a substantial number of contractors.
Reality Winner was a contractor, by the way: https://en.wikipedia.org/wiki/Reality_Winner
Multiple programs were built to fix the compensation for military members whom were paid even less than civilian counterparts in the same offices. It's why the churn rate is so high. Even then, the majority of cleared jobs still aren't commensurate with external salaries.