Armed police were called to the Kilda Crescent area of Templehall in Kirkcaldy on Monday after reports a man was wielding a knife and threatening to self-harm.
It’s understood the man refused to vacate premises and wouldn’t let police officers in.
Rumours on social media that the man was armed with a gun have been discounted.
Someone else was in the property but was free to come and go.
A Police Scotland spokesperson said: “Police in Fife were called to Kilda Crescent, Kirkcaldy, at around 3pm on Monday June 29 following reports of a disturbance.
“The situation was resolved peacefully and a 27-year-old man was subsequently arrested and charged and appeared at Kirkcaldy Sheriff Court on Tuesday June 30.”