Status of a book title at a publishing house
An out-of-print (OOP) or out-of-commerce item or work is something that is no longer being published. The term applies to all types of printed matter, visual media, sound recordings, and video recordings. An out-of-print book is a book that is no longer being published. The term can apply to specific editions of more popular works, which may then go in and out of print repeatedly, or to the sole printed edition of a work, which is not picked up again by any future publishers for reprint. 
Most works that have ever been published are out of print at any given time, while certain highly popular books, such as the Bible, are always "in print". Less popular out-of-print books are often rare and may be difficult to acquire unless scanned or electronic copies of the books are available. With the advent of book scanning, and print-on-demand technology, fewer and fewer works are now considered truly out of print.
A publisher creates a print run of a fixed number of copies of a new book. Print runs for most modern books number in the thousands. These books can be ordered in bulk by booksellers, and when all the bookseller's copies are sold, the bookseller has the option to order additional copies. If the initial print run sells out and demand still exists, the publisher will have more copies printed, if possible. When the book is no longer selling either at a rate fast enough to pay for the inventory or stock costs, or to justify another print run, the publisher will cease to print additional copies, and may remainder or pulp the remaining unsold copies. When all of the books in a print run have been sold to booksellers, the book is said to be "out of print", meaning that a bookseller cannot get any further copies from the publisher. If a book sells out unexpectedly quickly, it may be considered out of print briefly when its initial print run is exhausted, but is usually soon reprinted.
Publishers will often let a book go out of stock for long periods, then reprint the book, usually with a new cover and formatting, to catch the presumably built up demand for the book. The author or their estate may have copyright reverted to them once the publisher has declared it out of print.
Most publishing contracts contain reversion clauses allowing authors to regain the copyright to their books. One of the triggering conditions for this is an out-of-print clause which makes a book eligible for reversion to the author when a publisher no longer keeps a book in print. Often, rights do not automatically revert to the author. Instead, the author is responsible for requesting the book be put back in-print or, if the publisher declines, demand their rights back. 
In recent years, with the development of print-on-demand services and electronic formats of books, there has been much contention between publishers and authors as to what deems a book out-of-print. Publishers have begun to explicitly state which book formats qualify as in print, and typically include print-on-demand and electronic copies. 
At least one publishing company has adjusted their contracts to account for this change in publishing options by removing the lower limit for book sales, meaning that no matter how few copies of a book sells, if it is available through a print-on-demand vendor or electronically, it is still considered in-print.
The longer a book has been out of print, the more difficult it may be to obtain a copy. If there is enough demand for an out-of-print book, and all copyright issues can be resolved, another publisher may republish the book in the same manner as the original publisher might have reprinted it. In some cases, an out-of-print book, even one that sold very poorly, may be republished if the author becomes popular again.
A reader who wishes to purchase an out-of-print book must either find a bookseller who still has a copy, wait for another print run, or find someone who will sell their own copy as a used book. The advent of the Internet has made this process much easier, as many websites sell used books offered by bookstores and individuals.
Some publishers intentionally limit the print run of some or all titles to fewer copies than the anticipated demand, in creating limited editions marketed to collectors. In these cases, there is an implicit or explicit promise to collectors that the book will not be reprinted, at least in the same form as originally published. For instance, Madonna's book "Sex", with a limited edition print run, was the most requested out-of-print book from 2011 to 2015 in BookFinder.com and remains as one of the most in-demand out-of-print publications of all time according to Barry Walters from "Rolling Stone".