The feature allows friends to either click on an “I’m safe” or “I’m not in the area” icon and was initially introduced for natural disasters.
It also lets users know how many friends are in the affected area, number of people marked safe and those “not marked safe yet.”
Once a person is marked as safe Facebook sends a notification to their friends informing them that they’re ok.
The feature was activated after gunfire was heard just before 3pm in central London. A government minister has since confirmed a police officer was stabbed and the assailant was shot by armed police.
There are reports of further violent incidents nearby, and police say they have been called to a firearms incident on nearby Westminster Bridge.
Witnesses said a vehicle struck several people on the bridge, and photos showed a car plowed into railings.
Scotland Yard said the attack in Westminster was being treated “as a terrorist incident until we know otherwise”.
The Metropolitan Police added in a statement that the incident is ongoing and are urging people to stay away from the area.
The Parliament complex is now on lockdown. Deputy Commons Speaker Lindsay Hoyle told MPs they would be the last parliamentary staff to be evacuated, and would be moved out in groups of 20.
It was just a year ago that Facebook activated its Safety Check feature for the Brussels attacks which left 10 people dead.