A suicide bomber detonated an explosive device in the heart of the Turkish capital, Ankara, on Sunday.
A second assailant was killed in a shootout with police, the interior minister said.
The attack occurred hours before Parliament was set to reopen after its three-month summer recess with an address by President Recep Tayyip Erdogan.
Also read: Explosion at rally celebrating Eid-e-Miladunnabi kills 52 people in Pakistan
Two police officers were slightly injured during the attack near an entrance to the Ministry of Interior Affairs, minister Ali Yerlikaya said on X, the social media platform formerly known as Twitter. The assailants arrived at the scene inside a light commercial vehicle.
"Our heroic police officers, through their intuition, resisted the terrorists as soon as they got out of the vehicle," Yerlikaya later told reporters. "One of them blew himself up while the other one was shot in the head before he had a chance to blow himself up."
"Our fight against terrorism, their collaborators, the (drug) dealers, gangs and organized crime organizations will continue with determination," he said.
The minister did not say who was behind the attack and there was no immediate claim of responsibility. Kurdish and far-left militant groups as well as the Islamic State group have carried out deadly attacks throughout the country in the past.
Also read: At least 20 dead in gas station explosion as Nagorno-Karabakh residents flee to Armenia
Last year, a bomb blast in a bustling pedestrian street in Istanbul left six people dead, including two children. More than 80 others were wounded. Turkey blamed the attack on the outlawed Kurdistan Workers' Party, or PKK, as well as Syrian Kurdish groups affiliated with it.
Security camera footage on Sunday showed a vehicle stopping in front of the ministry, with a man exiting it and rushing toward the entrance of the building before blowing himself up. A second man is seen following him.
Earlier, television footage showed bomb squads working near a vehicle in the area, which is located near the Turkish Grand National Assembly and other government buildings. A rocket launcher could be seen lying near the vehicle.
Turkish authorities later imposed a temporary blackout on images from the scene.
Justice Minister Yilmaz Tunc said an investigation has been launched into the "terror attack."
"These attacks will in no way hinder Turkey's fight against terrorism," he wrote on X. "Our fight against terrorism will continue with more determination."
Also read: Suicide bomber at political rally in Pakistan kills at least 44 people, wounds nearly 200
Police cordoned off access to the city center and increased security measures, warning citizens that they would be conducting controlled explosions of suspicious packages.
The two police officers were being treated in a hospital and were not in serious condition, Yerlikaya said.
Egypt, which has normalized ties with Turkey after a decade of tensions, condemned the attack. A terse statement from the Foreign Ministry offered Egypt's solidarity with Turkey.
The U.S. Embassy in Ankara and other foreign missions also issued messages condemning the attack.
Erdogan's speech will be closely watched for indications as to when Turkey's parliament may ratify Sweden's membership in NATO.
Stockholm applied for NATO membership alongside Finland following Russia's invasion of Ukraine last year. While Finland has since joined, Turkey blocked Sweden's membership in the military alliance, accusing it of being soft on groups that Turkey considers to be security threats. Only Turkey and Hungary are yet to ratify Swedish membership.