Hospitals in Huddersfield and Halifax will introduce a total smoking ban in October as part of a nation-wide NHS campaign to make hospitals smoke-free.
The ban will affect Calderdale Royal Infirmary in Halifax, Huddersfield Royal Infirmary and St Luke's Hospital in Crosland Moor, Huddersfield.
It will apply to all hospital buildings and their grounds.
Preparations for the ban include the sale of nicotine replacement therapies at hospital shops.
Mark Partington, from the Calderdale and Huddersfield NHS Trust, said the ban was aimed at making sure nobody has to breathe in other people's smoke.