She came through two races and led the final from the start to triumph.
had to settle for omnium silver with the Olympic champion, losing her world title to Sarah Hammer.
Trott clinches omnium silver
But Britain's young team still end the week on top of the medal table in Minsk with nine in total, including five golds, to make a confident start on the road to the Rio Olympics in 2016.
Anna Meares was the last female rider to win four medals at a single World Championships, in Melbourne in 2012, while Victoria Pendleton's best was three, which she managed on three occasions from 2007 to 2009.
"Oh my gosh. I can't believe it. Wow. It's going to take a good week for it to sink in, or two weeks, or a month," a dumbfounded James said.
"I just need someone to pinch me and tell me if it's really happening to me. I feel like it's a complete dream apart from the pain in my legs."
James, from Abergavenny, was in action for the fifth straight day in Minsk but did not look tired as she sped to victory in her heat, then showed her tactical nous to squeeze through the field to make it through her semi-final.
Chris BoardmanOlympic cycling champion and BBC Sport summariser
Becky James would be fourth on the medal table just by herself. It's a bit of fun but it shows just what an enormous impact she has had on these championships.
Before she came here, if she could have signed on the dotted line for a single bronze medal, she would have grabbed the pen out of your hand, so to medal in all of her events, two of them gold is fantastic.
The way she rounded it all off in the keirin today was superb and it was quite a way to pick up Vicky Pendleton's mantle
She made the final look easy, leading out from the start and holding off Jinjie Gong of China and Lisandra Guerra Rodriguez of Cuba.
A poor performance in the points race on Saturday, when she finished 10th, proved decisive and, although she bettered American Hammer's results in two of the final three events on Sunday, she could not make up the lost ground.
Hammer is the individual pursuit world champion and after she had finished first in her specialist discipline, third and fourth places by Trott in the scratch race and time trial were not enough to reel the American in.
Trott, 20, who had already won team pursuit gold this week told BBC Sport: "A better rider beat me on the day. What more can I do?
"After the points race, I am happy to come away with a medal, so to end up with silver I am super happy."
There were no British men left in the final stages of the men's individual sprint after
were eliminated on Saturday.
Germany's Stefan Botticher took gold, after beating Russia's Denis Dmitriev 2-0 in their best-of-three battle, with France's Francois Pervis taking bronze.
Kenny lost in the quarter-finals but the 24-year-old from Bolton had the consolation of knowing he had beaten the new world champion in round two, before Botticher progressed via the repechage.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.