Church membership is the commitment to the local body of believers expressed throughout the New Testament by example and command. It is the metaphor used by Paul to describe individuals in the church: "Now you are the body of Christ and individually members of it." (1 Corinthians 12:27). It is a covenant (promise/agreement) between us and God in the context of a specific local body of believers.
The church is the instrument Jesus built to carry out the mission of God and is the context in which the commands of God are practiced as recorded in the Epistles. Exhortations such as: "Pay careful attention to yourselves and all the flock" (Acts 20:28), "Obey your leaders and submit to them" (Hebrews 13:17), and "Encourage one another and build one another up" (1 Thessalonians 5:11), are not possible or practical outside of the local church.