I recently saw a paper where there are presented some rules on how to learn mathematics (and do research) which were firstly articulated by Lagrange. Are there any similar rules that were expressed before early 1800s by other mathematicians?
Plato had a simple rule: learn geometry. This of course is well before the 1800s.
This is tempered by the time of al-Jabr who taught us to learn algebra.
Another heuristic is one by Newton who said 'he stood on the shoulders of giants'. This implies that one ought to study the works of the great masters of the subject thoroughly.
Another useful heuristic is by Solomon Lefschetz. Unfortunately this is after your cut off date, being in the early to mid 20C.
He had one simple rule: he said he wasn't interested in prettifying already established results, what he was interested was in original work that showed something new.
This is what he told the graduate students who were under his supervision.
Another heuristic, again unfortunately well after your cut-off date is by Atiyah who reminded students that there were a lot of gems in the work of older mathematicians and which had been forgotten. This, however, ties in with what Newton thought.