After police hunted an "active shooter" at the firm's complex in San Bruno, California, at least three people have been wounded, reports Sky News.
A woman suspected of wounding at least three people in a shooting at YouTube's headquarters has been found dead after apparently turning the gun on herself.
Officers hunted an "active shooter" at the complex in San Bruno, California, as panicked employees fled the scene on Tuesday afternoon.
Workers described barricading themselves in their offices and seeing blood splattered around the building during the carnage.
San Bruno Police Chief Ed Barberini said the female suspect was found dead inside the building with a "self-inflicted gunshot wound". She is believed to have been armed with a handgun.
Police confirm the female shooting suspect is dead
A 36-year-old man, who is in a critical condition in hospital after being shot, is thought to be the suspect's boyfriend, according to US media report.
Two other victims with gunshot wounds include a 32-year-old woman who is in a serious condition and a 27-year-old woman who is stable, a San Francisco General Hospital spokesman said.
Sky News US Correspondent Greg Milam said FBI agents were at the scene of the shooting but handed the incident over to local police, suggesting it was not terror-related.
Images posted on social media showed people being led out of YouTube's HQ with their hands above their heads.
YouTube employee Todd Sherman said he saw a "person with a gun" as he headed towards an exit to the building.
"I looked down and saw blood drips on the floor and stairs," he wrote on Twitter.
Another member of staff, Dianna Arnspiger, said she ran to a window after hearing gunshots and saw the armed woman on a patio outside.
The suspect was wearing glasses and a scarf and using a "big huge pistol", she said.
"It was a woman and she was firing her gun," Ms Arnspiger said.
"I just said, 'Shooter,' and everybody started running."
One witness said he helped a woman in her 20s who had been shot in the leg.
He said: "I saw the victim, she was in the dining room she had a wound in her leg and I put a tourniquet on her.'Victim was shot in the parking lot. The ambulance came and took her away. She said she was shot in the parking lot."
YouTube's owners Google said its security team was working with authorities to evacuate buildings and told employees to stay away from the area. The company has also set up a help line for workers.
Google chief executive Sundar Pichai called the shooting "a horrific act of violence", saying the firm will provide support to help staff "heal from this unimaginable tragedy."
US President Donald Trump said he had been briefed on the incident, adding: "Our thoughts and prayers are with everybody involved.
FU