Many shows use the same face template throughout. Why do they use this?
This is a matter of artistic style and a branding strategy.
As a prime example: Studio Ghibli films are arguably the highest-quality anime produced. They painstakingly aim for realism in the movements of characters and objects and the backgrounds are lush and extremely detailed.
The balance of light and shadow accurately matches real life, and every cell is intentionally still hand-painted in the studio to preserve the high quality (Roger Ebert's interview with Miyazaki Hayao reports, "Miyazaki, who is suspicious of computers, personally draws thousands of frames by hand. 'We take [handmade] cell animation and digitize it in order to enrich the visual look, but everything starts with the human hand drawing. And the color standard is dictated by the background. We don't make up a color on the computer'").
Not only do the Japanese think so, but Studio Ghibli's work has been internationally acclaimed for its impeccable quality. Without any interest in a computer-generated template, Studio Ghibli uses the same face character designs over and over.
There are four main points:
Only one of these blue-haired girls is Sailor Mercury:
Chiba Mamoru (Tuxedo Kamen) and his dead ringers from other series:
Tenou Haruka (Sailor Uranus) and dopplegangers:
Although many mangaka and anime character designers do this type of branding very well, it should be noted that this is not specific to manga and anime, but can be seen in other mediums in other countries.
For example, even while Disney intentionally adds hints of traditional cultural art styles into its films (eye shapes for Jasmine, Pocahontas, Mulan, Megara), facial design for Disney protagonists is, for the most part, easily recognizable as being Disney, regardless of the ethnicity of the characters.
It's easier for animators to keep one face pattern and differentiate through other features that are unique to that character - hair colour, hair design, eyes, etc.
The love-live girls are a good example of this. They're very unique at first, but their faces are mostly similar designs.
Some benefits of keeping the same face is that the animators only have to learn that single type of face, meaning less time redrawing as they should be very used to it.
Also, in certain scenes characters may be switched out for others if the director decides it. This means that only the hair / peripherals would have to be changed - rather than the entire body. Even if they are somewhat different - changing a the colour of an eye is a matter of a simple image tool's slider. It also means that facial features can be mostly left alone if there is a significant rush for release. Your first image is a good example of this.
Anime also is a medium that has gone through years of refinement. If you watch a show about schoolgirls - there's a certain subset of design that this will fall into - you aren't going to get gritty speedlines and heavily shaded faces unless in the case of a gag.
Combine this with the artist's particular style which is an important feature for first-glance recognition - and the fact that anime characters are significantly less detailed than real-life humans, means that a lot of characters can look the same.
This is what has lead to all the crazy pink, purple, blue hair colours that are so common (and presumed natural) in anime.
In summary: Character designs are limited in several ways, so animators prefer to spend time on other parts of anime characters instead
Everyone can relate to.
The more basic a face looks, or the less it looks like anyone in particular, the more relateable it will be.
You might notice in many series (especially within the Shounen genre) this trope really only applies to the main cast, where sameface will be applied equally regardless of race. If a villain is supposed to be cute, or sympathetic in some way, they will be granted sameface.
However, more and more distinguishing features will be added the more a character is to be viewed as either unimportant or an unredeemable bastard. Other examples of breaking the trope include trying to visually push a character trope.
For example, the tiny but relateable girl will be given less of a nose than the other main cast, or the strong guy of the bunch will have a more defined nose or squared shin tip, but they will both have generally the same structure.
Because they produce like 100 anime every year or something. They have to be fast at it and we all know how the Asian market is low when it comes to quality. Sure thing Studio Ghibli and other studios that make movies (like the Vampire Hunter D) can do wonders, they choose not to when it comes to mass production.
Effectively, the different characters rely heavily on the hair and little bit on eye colour and/or shape. Especially filler characters that might not really play a huge role will have the generic anime face with some average hairstyle.
This is also why in anime all characters wear one and one single outfit ONLY throughout the whole series. Give them a different clothing and they turn into a different character.
For example, there was an episode in Sailor Moon where Sailor Venus had pigtails on purpose to pretend she is Sailor Moon to distract the enemy from the real Sailor Moon, she was identical in every aspect and the only thing that made her different was the length of the pigtails since Sailor Moon has knee hair length while Venus hip length hair.
At some point, they will have used all possible hairstyle, hair colour, and outfit combinations and they will have to upgrade in style.
Western cartoons also tend to have a continuation throughout the series, you won't see them change the hairstyle or clothing too much, but many times they portray the hair and clothing and face more realistically different than the typical anime face with spiky otaku hairstyle with glasses or not.