The Argentine scored three times to surpass Telmo Zarra, as his side eased to a win at the Camp Nou.
Lionel Messi became La Liga's all-time leading scorer with a hat trick in Barcelona's 5-1 win over Sevilla.
The prolific Argentinian took the his tally of Spanish top-flight goals to 253 with a treble, moving past Telmo Zarra's record of 251 that had stretched back to 1955.
Messi, who made his Liga debut in 2004, has achieved the feat in 289 appearances – 11 more than the legendary Athletic Bilbao forward Zarra.
The 27-year-old found the net with a delightful first-half free kick, placing it into the top corner to move level, before claiming the landmark outright in the second period as he capped a memorable evening.
His first La Liga goal came as a 17-year-old against Albacete in May 2005, and he had not scored in the league since netting at home to Eibar on Oct. 18.
But his wait for another career milestone ended in style as Barca continued its title push with a resounding success.
After Messi's superb set piece had ensured he would dominate the headlines, Jordi Alba's own goal at the start of the second half brought Sevilla level.
Barca was ahead again in the 49th minute as Neymar headed past Beto. Ivan Rakitic, who captained Sevilla to UEFA Europa League glory last season, nodded in with 25 minutes to go to make it 3-1, but the day belonged to Messi.
He slid a shot home with 18 minutes left to finally overtake Zarra, before completing his hat trick and rounding off a stunning performance with a solo goal in the 78th minute.
Messi was presented with an opportunity he would have been expect to bury in the eighth minute. On this occasion, he fired a tame effort straight at Sevilla's Portuguese goalkeeper Beto before Luis Suarez was also denied three minutes later.
But normal order was restored after 21 minutes, as Messi took center stage. His sublime free kick from just outside the area curled into the top-left corner.
Sevilla looked bright at the start of the second half and it was level in the 47th minute as Vitolo skipped past two challenges down the left and saw his cross turned in by Alba.
The away side was on level terms for just a few moments, though, as Neymar steered home Xavi's deep free kick with a fine glancing header.
Sevilla's forays forward in search of an equalizer ultimately proved to be its undoing, as Barca soon netted its third on the counterattack, Rakitic heading in Suarez's cross to effectively end his former team's chances.
He chose not to celebrate, but Messi offered Sevilla no such courtesy – and rightly so – as he claimed his place in the history books.
The Argentina star slotted in an easy finish after good work from Neymar in the 72nd minute, delighting the Camp Nou faithful.
He then added Barca's fifth and his third to round off an historic night, jinking past a couple of challenges before firing low after a clever interchange with Neymar.