BEIRUT, Lebanon — Islamic State fighters are preventing fuel shipments from reaching rebel-held parts of northern Syria, causing severe shortages that are grounding ambulances, paralyzing medical centers and shutting down bakeries, according to antigovernment activists and aid workers.

Adding to the misery, international aid groups said, the forces of Syria’s president, Bashar al-Assad, are targeting medical centers in opposition areas, killing some workers and forcing facilities to shut down.

The fuel shortages highlight how more than four years of war in Syria have ravaged the economy and allowed the warring parties to use the country’s scarce resources as a vise to squeeze their enemies.

Since the Islamic State, also known as ISIS or ISIL, seized oil-rich regions in Syria’s north and east, it has used the output to finance its efforts to build an Islamic caliphate that straddles the Syria-Iraq border.