PurposeTo provide information on magnetic lens design principles for neutron beam focussing and to characterize the efficiency of these devices.Design/methodology/approachMagnetostatic and neutron optical computations are presented for permanent magnet and electromagnetic hexapole lenses for neutron beam focusing. The numerical results are verified by magnetic and neutron beam measurements.FindingsNeutron lenses built from brick‐shaped permanent magnets approximating the six‐pole Halbach structure yield relatively high field constant for a relatively small useful diameter. Electromagnets are weaker, but allow field constant adjustment.Research limitations/implicationsThe main limitation of both presented solutions resides in the difficulty of obtaining high magnetic flux densities. Superconducting coils in hexapole configuration can overcome this limitation.Practical implicationsThe magnetic lenses can be used for beam focusing in scattering neutron instruments. The focused beam is also polarized.Originality/valueAnalytical formulae are supplied for the neutron path calculation in a six‐pole magnetic field. An electromagnet design with permanent magnet flux enforcement is provided.