His 110 means he has scored 323 runs in a week after an unbeaten 93 against Glamorgan in the One-Day Cup and 120 not out against Kent in the T20 Blast.
Tim Murtagh (2-85) reduced Surrey to 23-2 inside the first six overs, before Rory Burns (88) aided the recovery.
Burns and Roy put on a 118-run fourth wicket stand as Surrey closed on 384-8.
Roy's century was a fine retort against Division One leaders Middlesex, who dismissed the England limited-overs opener for a first-ball duck in the One-Day Cup on Tuesday.
After paceman Murtagh removed both Zafar Ansari and Dominic Sibley early on, Surrey's slump continued as James Franklin trapped Aaron Finch (37) to leave them 70-3.
Burns helped turn their fortunes around as he hit 15 fours in his 127-ball knock as the visitors seized the initiative.
Roy hit 16 fours himself as Surrey edged close to the 400 mark by the end of the first day's play, with Ben Foakes unbeaten on 53.

Recent online leaks showed some officials were receiving over 100 times more than an average public sector worker on about $400 (Â£305) a month.
The cap for government officials is now set for $2,630 and $5,250 for those in the mixed state-private sector.
Public anger has already led to the sacking of several bank directors.
One of them was paid about $60,000 a month, according to leaked payslips. However, it was not clear whether it was the director's monthly salary or total earnings, including a bonus.
Any payment beyond the new limits would now be seen as "a violation and crime", government spokesman Mohammad Bagher Nobakht said on Tuesday.
The row has also given conservative critics of President Hassan Rouhani new ammunition to attack him ahead of his likely bid for re-election next year.

Haigh, 39, left Leeds in April 2014 after Massimo Cellino bought the club.
"Penzance is a great grounding of a club, with an awful lot of potential to grow in the community," Haigh told BBC Radio Cornwall.
Penzance are bottom of the South West Peninsula League Division One West, the 11th tier of English football.
"The club contacted me through Twitter asking if I could help out," Haigh said. "I'd had one or two offers since Leeds, and I said no to them.
"But, the reason why I said yes to Penzance is because of the potential. They're at the bottom, so they can only go up.
"What I liked when I chatted to the committee was the passion. They're without debt, they can build on that and that's why I was really interested."
After leaving Leeds, Haigh moved to Dubai where he was acquitted in March over charges of sending an offensive tweet about a business partner.
But, he served a two-year sentence on separate charges of financial misappropriation.
Haigh, who grew up in Cornwall and has relocated to the county since leaving Dubai, will be sponsoring Penzance rather than financially backing them.
"There's no reason why clubs in Cornwall can't play at a higher level," he added. "But, it's going to take some investment in terms of infrastructure."
Jason Roy continued his fine form with a second century in six days as Surrey made a strong start with the bat against Middlesex at Lord's.
[NEXT_CONCEPT]
The Iranian government says it will cap salaries of public officials after a row over the high level of pay of some employees.
[NEXT_CONCEPT]
David Haigh, the former managing director of Leeds United, has been appointed as a committee member at Cornish non-league side Penzance AFC.