Protecting source code files by permission ensures that only authorized users can access and view the source code files within Jenkins. When this option is enabled, users must have the appropriate WORKSPACE permission to view the source code files associated with builds. This helps to maintain the confidentiality and integrity of the source code, preventing unauthorized access and potential security risks.