An adult UK passport is valid for 10 years from the date of issue, and a child UK passport is valid for 5 years.
Passports must be renewed before this if your appearance changes significantly and permanently, or if you change your name.
Most countries require a minimum of 6 months before the passport expiry date, in order to pass through a point of entry. Most EU countries require only that the passport be valid for 1 day beyond the length of your stay, but this changes and should be checked before travelling.
The UK is not part of the Schengen Zone, and so UK citizens have to produce a passport when entering any EU country at a monitored point of entry such as an airport or sea port. Land crossings – road, rail etc. – within the EU are largely unmonitored and unrestricted travel is usually possible.