PSR J0218 + 4232 is a millisecond pulsar ( MSP ) with a flux density \sim 0.9 mJy at 1.4 GHz . It is very bright in the high-energy X-ray and \gamma -ray domains . We conducted an astrometric program using the European VLBI Network ( EVN ) at 1.6 GHz to measure its proper motion and parallax . A model-independent distance would also help constrain its \gamma -ray luminosity . We achieved a detection of signal-to-noise ratio S/N > 37 for the weak pulsar in all five epochs . Using an extragalactic radio source lying 20 arcmin away from the pulsar , we estimate the pulsar ’ s proper motion to be \mu _ { \alpha } \cos \delta = 5.35 \pm 0.05 mas yr ^ { -1 } and \mu _ { \delta } = -3.74 \pm 0.12 mas yr ^ { -1 } , and a parallax of \pi = 0.16 \pm 0.09 mas . The very long baseline interferometry ( VLBI ) proper motion has significantly improved upon the estimates from long-term pulsar timing observations . The VLBI parallax provides the first model-independent distance constraints : d = 6.3 ^ { +8.0 } _ { -2.3 } kpc , with a corresponding 3 \sigma lower-limit of d = 2.3 kpc . This is the first pulsar trigonometric parallax measurement based solely on EVN observations . Using the derived distance , we believe that PSR J0218 + 4232 is the most energetic \gamma -ray MSP known to date . The luminosity based on even our 3 \sigma lower-limit distance is high enough to pose challenges to the conventional outer gap and slot gap models .