Community answers are sorted based on votes. The higher the vote, the further up an answer is.
By my understanding and belief, the books that compose the modern Bible were ultimately a product of divine inspiration both on the part of the individuals who originally wrote them down, and of the multiple individuals and ecclesiastical bodies (both Jewish and Christian) that have identified, attributed and assembled them throughout history since prior to the birth of Christ -- all (as Christians believe) under the guidance of the Holy Spirit. Although they have undoubtedly been copied or transcribed many times since their initial writing, they have, through God's involvement in keeping with Jesus' words in John 14:26, been preserved free from error. I also found the discussion of this issue on the Got Questions? Website (https://www.gotquestions.org/canon-Bible.html) to be a useful resource in considering this question.
What you are asking is termed "canonicity of the Bible", which essentially answers the question about how the Bible came to be what it is today. There are many apologetics websites which deal with this topic in depth, as well as many books - this is one of them: https://www.josh.org/who-decided-what-in-bible/?mwm_id=241874010215&mot=J79GNF&gclid=EAIaIQobChMIpeKduezJ4wIVkI7ICh0mHQefEAAYASAAEgKkv_D_BwE What we see in the physical world are people writing books or letters with their own personalities, while in the spiritual world God is guiding and shaping the final product so that it says what He wants. Peter explains the process as "For prophecy never had its origin in the will of man, but men spoke from God as they were carried along by the Holy Spirit" (2 Peter 1:21). These writings were recognized by God's people as the Word of God and collected and distributed among locations where they gathered. Eventually, a council (the Council of Nicea) listed officially what most people already accepted and formalized the collection.
All answers are REVIEWED and MODERATED.
Please ensure your answer MEETS all our guidelines.
A good answer provides new insight and perspective. Here are guidelines to help facilitate a meaningful learning experience for everyone.