The 22-year-old is likely to provide back-up for new signing Ross Etheridge.
“I’m delighted to have signed,” Marosi told Rovers' official website.
"I wanted to stay here and the gaffer knew that. He’s given me a chance and hopefully I can now prove to him that I can do something.
“I’ll be coming back after pre-season in good shape and I just want a chance to prove myself to the gaffer and I can’t wait for pre-season to start with the lads.
“My main reasons for wanting to stay here were the gaffer and his philosophy. His playing style suits me and Paul Gerrard has had a huge influence over me since being here. We get along very well and I’ve always enjoyed the type of training that we do.
“The main aim for us this year is promotion with the squad we have."
Marosi, who has represented Slovakia at Under-21 level, has made six appearances for Rovers since arriving from Wigan in 2014.