This is common mythology but it's a bit more complicated than that if you look at the data. Student performance is highly correlated with their parent's socio-economic status – a trend going back roughly a century in studies – and our educational system includes a wider range of students differing in both SES and, starting around that same time period, mainstreaming of many disabilities which used to get kids excluded.
That means that when you're making comparisons to either the past or other countries now, you want to compare cohort-matched groups. If your area has a bunch of poor brown kids used to leave school for jobs in the 8th grade and are now going all the way through graduation, that looks like the schools are getting worse even though the school's educational practices haven't changed and the problem you really want to solve is poverty or social mobility. This is especially true for international comparisons if you have things like tests where the population in one country going in is highly selective but broader somewhere else – everyone's acting in good faith but you still have distortion due to sampling bias.
The situation is similar: if a kid with dyslexia, ADHD, etc. in the 1960s would have been pushed out but now they're included, if you're looking at the global average it looks like test scores have gone down but if you look at subgroups of the student population you'll see that the top performers are still doing well and what changed was that another group was added.
At my son's school and some of the schools I went to as a kid, the subgroup breakdowns on stats are really stark: the kids from stable, middle-class or better groups do fine but the children of immigrants who are still working on their English skills struggle – and the lesson I've drawn is that we should have more support available for them outside of regular classes because it's such a powerful amplifier for everything else.