ISTANBUL — Turkey plunged into the fight against the Islamic State on Thursday, rushing forces into the first direct combat with its militants on the Syrian border and granting permission for American warplanes to use two Turkish air bases for bombarding the group in Syria.

The developments ended a longstanding reluctance by Turkey, a NATO member and an ally of the United States, to play a more aggressive part in halting the Islamic State’s expanding reach in the Middle East. American officials said it carried the potential to strike Islamic State targets with far greater effect because of Turkey’s proximity, which will allow more numerous and frequent bombings and surveillance missions.

Turkey, a vital conduit for the Islamic State’s power base in Syria, had come under increased criticism for its inability — or unwillingness — to halt the flow of foreign fighters and supplies across its 500-mile border.

Up to now, Turkey has placed a priority on dealing with its own restive Kurdish population, which straddles the Syrian border in the southeast, and in the toppling of Syria’s president, Bashar al-Assad, whom the Turks blame for creating the conditions in his war-ravaged country for the rise of Islamic extremism.