Dublin City Council Chief Executive Owen Keegan has apologised for saying students should provide their own accommodation, but said he would not be resigning.
A protest was earlier held outside the council's civic offices following remarks by Mr Keegan about student accommodation.
The demonstration was led by UCD Student Union President Ruairí Power, who last Monday called for the resignation of the council's CEO.
Mr Keegan had suggested that student unions should organise Purpose Built Student Accommodation (PBSA) themselves after a student leader complained about short term letting of such units.
Taoiseach Micheál Martin welcomed Mr Keegan's apology, saying that it was good that regret was expressed.
Today's rally followed calls by councillors on the housing committee for Mr Keegan to withdraw his remarks.
The Sinn Féin group of councillors on the committee had called on him to resign, while almost all councillors called on him to withdraw his remarks.
Mr Keegan has now apologised for stating that students should provide their own accommodation but said he would not be resigning.
He said he had been making a serious point as student unions in many countries do provide or operate accommodation.
However, the Dublin City Council CEO accepted there was an "element of sarcasm" in his statement.
"I did not consider that the reliance on sarcasm was necessarily inappropriate in the context of an exchange of robust correspondence.
"However, on reflection, I now accept that the use of sarcasm was inappropriate on this occasion and I am happy to apologise for the offence I caused," he added.
Addressing the protest earlier today, Mr Power said it was not just about Mr Keegan's "sarcastic remarks", but the general lack of affordable student accommodation.
An exchange of letters between Mr Keegan and Mr Power occurred after the council's planning department allowed beds in a 571-unit student accommodation complex in Smithfield to take in tourists during the current academic year.
The temporary permission was granted to the owners, Uninest, until May 2022.
Mr Keegan informed the student union president that the permission was granted on the basis of circulars from the Department of Housing, which allowed tourist use when a building was not required by students.
It was also to encourage occupancy and footfall in the city centre at a time when there was low occupancy by students due to the Covid pandemic.
Mr Keegan pointed out that there were no objections or appeals made to oppose the application.
However, in his reply, Mr Power accused the council CEO of allowing rents to remain high by permitting short-term letting.
In his final reply, Mr Keegan said he was surprised the students' union did not enter the housing market themselves.