The decision limits their ability to campaign in fresh regional elections are due to be held in Catalonia on December 21.
Former Vice President Oriol Junqueras, former Interior Minister Joaquim Forn, and the leaders of the Catalonia National Assembly (ANC) and Omnium Cultural, Jordi Sànchez and Jordi Cuixar, face charges of sedition, rebellion and misuse of public funds.
"The judge does not believe there is a risk of flight, but understands the risk of a repeated offense in the case of the four people held in prison," the court statement read.
Six former cabinet members of the now disbanded Catalan parliament were released on bail of 100,000 euros (about $118,000.)
The former President of Catalonia Carles Puigdemont is due to appear in Brussels today for an extradition hearing to send him to Spain, where he also faces trial.
Puigdemont, and four of his disbanded cabinet, are in self-imposed exile in Belgium under conditional release after an international arrest warrant was served against them.
Junqueras was to head the list of the far-left pro-independence ERC in the upcoming Catalan election, according to the Spanish news agency EFE. Election campaigning is due to begin at midnight local time.