When you use MLA 9th edition
MLA is the style of the Modern Language Association and it dominates English, literature, languages and most of the humanities. The current 9th edition came out in 2021, and it kept the container system that the 8th edition introduced, so anything you learned then still holds.
The container idea is the key to the whole style. Every source is described by the same list of core elements in the same order: author, title of source, title of container, contributors, version, number, publisher, date, location. A poem sits inside an anthology, an article sits inside a journal, a video sits inside YouTube. You fill in the elements that exist and skip the ones that do not.
That system is flexible, which is great once you know it and confusing the first ten times. The generator above applies the element order for you, so the fastest way to learn the pattern is honestly to run a few of your own sources through it and read what comes out.
The formats, with real examples
Paste your source into the tool above and it fills these in for you. If you would rather see the pattern, here is exactly what each one looks like.
In-text citations
Two authors: (Smith and Lee 24). Three or more: (Smith et al. 24). No page numbers, as on most web pages: just (Smith). No author: a shortened title in quotation marks, like ("Climate Change").