This is a common question as people fear turning off the water will damage their boiler in the mistaken belief that it might overheat, much like a boiling kettle without any water in it.
This is not the case as the water that comes out of your taps is not the same water that passes through your boiler. The water being heated by your boiler is in a closed loop being continually heated, cooled and circulated to warm up your radiators and exchange heat to your tap water.
By turning off the water you will only be cutting off the supply to your taps and, if your heating system has them, to the cistern tanks and storage cylinders.
Combi boilers will continue to provide heating, if required; but with the mains water supply turned off the combi will simply not function for hot water.
If you have a conventional (heat-only) boiler or a system boiler and you turn off the water, it will carry on heating up the radiators. You might even get a little hot water out of the cylinder, but that will quickly cease without any pressure or new water entering the system.
If you wish to turn off your boiler when you go on holiday, consider your decision carefully. While it is safe to do so in Summer, it is recommended that you keep your boiler switched on in Winter when temperatures can get quite low, in order to provide frost protection.