Marvin Solano's men have been involved in a battle with Deportivo Saprissa at the top and both have held first place at stages this season.
But after Saprissa drew 1-1 at Limon on Saturday, Herediano took advantage with a 4-2 victory at home to Santos de Guapiles.
Herediano (30 points) sit just ahead of Saprissa (29), while Alajuelense (22) have a game in hand in third.
In Heredia on Sunday, mid-table Santos de Guapiles stunned the hosts thanks to Antonio Salazar opening the scoring on five minutes.
But Solano's side were 3-1 ahead before half-time as Esteban Granados, Victor Nunez and Francisco Calvo netted.
Nunez scored his ninth league goal of the season to make it 4-1 on 79 minutes, before Juan Solis netted a consolation effort for the visitors.
Saprissa were forced to come from behind to take a point from fifth-placed Limon.
Mayron George's 12th-minute opener was cancelled out by Carlos Saucedo in the first half as the teams shared the spoils.
Alajuelense were also held to a 1-1 draw as Puntarenas came from behind to clinch a point.
Fourth-placed UCR drew level on points with Alajuelense thanks to a 2-1 win at Belen Siglo XXI, while Uruguay were 2-0 winners at home to Cartagines.
Perez Zeledon's struggles continued as Francisco Rodriguez's first-half brace saw Carmelita to a 3-1 home win over the league's bottom side.
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.