The Quebec City mosque shooter told police he launched his attack because he feared Canada's immigration policy after Donald Trump's "Muslim ban".
The day before the January 2017 shooting, Prime Minister Justin Trudeau tweeted his support of refugees.
A Canadian court watched Alexandre Bissonnette's police confession during his sentencing hearing on Friday.
The 28-year-old pleaded guilty to six counts of first-degree murder and six counts of attempted murder in March.
Bissonnette stormed into the Quebec Islamic Cultural Centre on 29 January, 2017, and opened fire, killing six Muslims. Five others were seriously injured.
It was retweeted 418,000 times, liked by over 768,000 Twitter users, and received widespread media coverage.
Bissonnette admitted during the confession he had mental health struggles, and had been prescribed medication to deal with anxiety.He had taken a three-week mental-health leave from work, he said, and was due to return on January 30.
His sentencing hearing continues next week, when victims are expected to give their statements.