Where is a patent valid and how long does it last?

A patent is valid in the particular country in which it is granted and for a certain period of time, generally 20 years from the date of filing the patent application.

Further information on patentability can be found in the European Patent Guide, Chapter 3 ‒ Patentability.