A barracks in the free game C-evo is a building available as soon as you research Warrior Code (which you need before designing any new ground units).
Troops built in a city with a barracks start life hardened. Troops stationed there double their health each turn until reaching 100%, which is a distinct improvement on the 20 percentage points increase that applies to a unit with over 20% but under 80% health in a city with no barracks. (The matching facilities for air units and naval units are Airport and Dockyard.)
Unlike the counterparts in Civ1 and Civ2, barracks never become obsolete.
In just one of each nation's cities, the barracks may be replaced by a Military Academy, which costs more to build and maintain but produces elite troops; the barracks are automatically sold. If you sell the academy (either directly or by completing one in another city), the barracks do not automatically reappear but must be built if you want them.