The boundary limit is 25 million documents inside the library, however you will come accross the List View Threshold limitations when you add more than 5.000 items (documents and/or folders) in the same folder.
There are many discussion on how to handle this, but basically you need to create views that filter the documents (in order to return less than 5000 documents) and index on the filtered properties. Take a look at this answer.
Obviously, just using search is perfectly fine. Trying to organize the content into different views is the only thing affected.
Changing the LVT from Central Administration is not a solution. It is the same as sticking your head into the sand hoping the problem will go away. It is not recommended by Microsoft and will cause performance issues with your servers.