In knitting, a lifeline is a smooth piece of yarn, usually of lighter weight than the working yarn, that is inserted into the knitting periodically. It’s used to prevent lost stitches when ripping out, or frogging, the work. Mistakes happen. We all do it. Lifelines can be saviors, especially when working lace or some other complicated bit, when those mistakes are discovered too far away to make undoing the knitting one stitch at a time a feasible thing to do. Multiple lifelines can be used in each project. They’re often inserted after each successful pattern repeat.
Using either a needle (easier) or crochet hook (if a needle isn’t handy), or circular needles with a hole large enough near the base and thread a smooth, contrasting yarn through all the stitches on the needle from one end of the row to the other. I usually tie the two ends of my lifeline together, so that it won’t fall out accidentally—Yes, this has happened to me… more than once—Continue knitting, while avoiding putting the needle through the lifeline, as this makes it quite difficult to remove later—yup, did this one, too.
Leave any lifelines in the work until all rows have been knit, and the project has been cast off. This is another trick of mine that I learned the hard way. Pulling out a lifeline before you’re done causes mistakes to show up that would be relatively easy to fix had that lifeline still been in place. Ask me how I know.