These days, website content is continually updated, websites are frequently redesigned, and URL structure is altered. Inevitably, 404 error pages occur on all sites—for various reasons.
"The website hosting server will typically generate a '404 Not Found' webpage when a user attempts to follow a broken or dead link; hence, the 404 error is one of the most recognizable errors encountered on the World Wide Web," according to the Wikipedia entry for "HTTP 404."
Search engines won't necessarily penalize you if you have 404 errors, but too many of them… and the user experience and website usefulness begin to suffer—and that can affect how search engines rank your site.
An infographic from data-driven digital marketing agency Spiralyitics provides more information on what 404 errors are all about, how you might correct them, and which tools are useful for finding and correcting them.