A bystander at the corner of St-Joseph Street and Parc Avenue flagged down a passing patrol car, concerned about a situation inside a pharmacy.
Montreal police Const. Abdullah Emran said officers arrived at the scene while the suspects were inside.
"They (the officers) managed to get into the store and as they went in, they realized there was an ongoing robbery," he said.
"So they saw both suspects and they arrested them while in the act."
Police arrested a 17-year-old and an 18-year-old at the scene. They say a weapon was found on site.
Nobody was hurt.