Luis Suarez, who scored twice, helped tee up Messi's landmark goal, which came in the 53rd minute of the Argentine's 435th league appearance for Barca and saw the league's top scorer increase his tally to 17 goals in 17 games this campaign.
Suarez had given Barca the lead in the 19th minute by completing a superb team move involving Messi and his former Liverpool team mate Philippe Coutinho, who returned to the starting line up for the first time in four league games.
The Uruguayan again combined with Coutinho to set up the historic goal for Messi, who produced a typical low shot into bottom corner after the lay off from Suarez.
It was another remarkable milestone for Messi, who has been the league's leading scorer since 2014, with Cristiano Ronaldo next on the list with 311 goals.
Eibar had been stubborn opponents in the first half but began to cave in after the interval, with Suarez striking again six minutes later, converting from a tight angle with the aid of a deflection off a visiting defender.
Barca, under pressure to win after Atletico Madrid had briefly reduced the gap to two points by beating Levante 1-0 earlier on Sunday, moved on to 43 points after 19 games.
Atletico are second on 38, while Sevilla are third on 33 after losing 2-0 to Athletic Bilbao.
Suarez's goals took him on to 14 league strikes for the season and means he and close friend Messi have scored a remarkable 31 times between them this season -- more than the total goal tallies of 17 teams in the league. (Reporting by Richard Martin)
(This story has not been edited by Devdiscourse staff and is auto-generated from a syndicated feed.)