Veterans will be identified on the census for the first time in a bid to improve mental health support.
The question "have you previously served in the UK Armed Forces", before specifying if the person served in a regular or reserve role, will be asked to allow the Government to better understand the profiles and needs of the ex-military community.
The Cabinet Office said that this will allow for "stepped up services for veterans, with better data and understanding allowing for more targeted and efficient support".
It also added that the data from the 2021 census will be "an important part of ensuring that mental health support for former service personnel is as effective as possible".
It comes after a recent Help for Heroes survey found that four in 10 wounded veterans living with life-changing injuries have experienced delays in NHS treatment during lockdown.
Meanwhile, another study by the charity last year found that British military veterans who suffer from post-traumatic stress disorders wait an average of four years to seek support.
Johnny Mercer, the veterans minister, said the move was "a huge step forward in better understanding the cohort of veterans living in this country [and] better data will mean better public services for veterans".
Charles Byrne, the director general of the Royal British Legion, who led a campaign to get the question put on the census, said it "will significantly improve our understanding of the Armed Forces community, which up until now has been very limited".
Mr Byrne said: "It will ensure that we, along with other charities and service providers, can deliver the best service possible to them when and where it is needed most."
He added that it would have "a huge impact on service personnel, veterans and their families well into the future, as the outcome will allow us to provide more effective care and support to those who are in need".
The results from the next census, due to be held on March 21 next year, will be available the following year.
The census will be able to be completed online on any device, as well as with help and paper questionnaires.
Veteran Darren Fuller, 44, served for 20 years in the army, including tours of Northern Ireland, Macedonia, Iraq and Afghanistan, where he was injured in 2008 and subsequently medically discharged in 2014.
He said: "The change to the 2021 census will make it easier for others like me to access the support they need, adding that it would help "generations of veterans like myself for years to come."