The hacker collective Anonymous took responsibility in an online video, saying it was done in protest of a controversial anti-terror law that dramatically expands the powers and reach of Canada's spy agency.
The government's public website for applying for social services and downloading official forms was briefly shut down in the cyber-attack, Treasury Board President Tony Clement said in a Twitter message, while those of Parliament, Industry Canada and Public Works also appeared to be down.
"Confirmed today that the Govt of Canada GC servers have been cyber-attacked," Clement tweeted.
Steven Blaney, minister of public safety, confirmed that other government websites had also been hit, but said individuals' information was safe.
"The cyber-attack and cyber-security is an issue that we take very seriously," Blaney said.
"We are increasing our resources and polices to be better equipped to face cyber-attacks, whether they are coming from hackers from a group, potentially, that has said they did it today, (or) state-sponsored or terrorist entities."
Bill C-51, said the group of hackers, violates Canadians' civil rights, and targets "minority groups and dissidents."
"Do we trade our privacy for security?" asked an electronically masked voice in the video.
The bill was enacted in response to the first terror attacks on Canadian soil last October, when a gunman killed a ceremonial guard and stormed parliament, and a soldier was run over in rural Quebec.
However it has been widely decried as overreaching and an unprecedented assault on civil rights.
It criminalises the promotion of terrorism, makes it easier for police to arrest and detain individuals without charge, and expands the Canadian Security Intelligence Service's (CSIS) mandate from intelligence-collection to actively thwarting terror plots and spying outside Canada.
Get your daily dose of tech news, reviews, and insights, in under 80 characters on Gadgets 360 Turbo. Connect with fellow tech lovers on our Forum. Follow us on X, Facebook, WhatsApp, Threads and Google News for instant updates. Catch all the action on our YouTube channel.