The tt¯ charge asymmetry is measured in proton–proton collisions at a centre-of-mass energy of 8 TeV . The data, collected with the CMS experiment at the LHC, correspond to an integrated luminosity of 19.7 fb −1 . Selected events contain an electron or a muon and four or more jets, where at least one jet is identified as originating from b-quark hadronization. The inclusive charge asymmetry is found to be 0.0010±0.0068 (stat)±0.0037 (syst) . In addition, differential charge asymmetries as a function of rapidity, transverse momentum, and invariant mass of the tt¯ system are studied. For the first time at the LHC, the measurements are also performed in a reduced fiducial phase space of top quark pair production, with an integrated result of −0.0035±0.0072 (stat)±0.0031 (syst) . All measurements are consistent within two standard deviations with zero asymmetry as well as with the predictions of the standard model.