Read your book out loud. Reading your book out loud will identify the sentences and dialogue that are awkward or don't make sense.
Give it to a trusted friend or family member. Truthfully, your friends and family aren't the best judge of whether or not your book is publishable, but they can provide helpful feedback on spelling, grammar and continuity.
Join a writers group. Writers groups offer support and encouragement during the writing process. Plus, they can offer helpful feedback on your work. Most groups won't read your work in its entirety. But if you go regularly, you can get feedback on the material as you write it. Writers will critique your work as writers (as opposed to your friends, who are readers) and help you flesh out your ideas, point out areas in which the writing slows down and give you ideas to improve your work.
Hire a professional to critique your work. This costs money, but it can be worth it to learn all the areas in which you can improve your book. Critiques can focus just on the editing for grammar and spelling, but for publishing you'll also want a critique on the content and how well it is presented. Ask members of your writers group or join online writers groups for referrals to people who offer critique services.
Send it to agents or publishers. Ultimately the judge of the quality of the book can be made by trying to sell it. Send your work to a small list of agents and publishers to start. Most won't offer any feedback, but some will. Make the fixes and send it off to more agents or publishers. Eventually someone may buy your book. But even if your book doesn't get an agent or publisher, that doesn't necessarily mean it's not good. The world is littered with successful writers who have hundreds of rejection letters.