A man has been arrested and a machete removed from a Sydney court after an incident that sparked a security lockdown.

The man in his 20s was seen lying on the floor in the foyer of the Downing Centre court complex surrounded by police after 10:00am.

After entering the CBD court complex, the man reportedly told people to "get on the ground".

It is believed people in the building were told to stay on the ground, and some may have hidden under their desks during the incident.

During the incident, a female police officer drew her gun and pointed at the man, a male court staff member told AAP.

Loading

"That's when I decided I was going down on to the floor," the employee said.

The man was led to a police van in handcuffs a short time later.

A police officer was seen leaving the court carrying a black machete.

Another officer seized items including a pair of boots and a camera — both believed to belong to the man — from a security screening area inside the building.

A number of police are still outside the court building, which remains closed to the public.

The court complex has since reopened.

AAP