It is loosely based on the book by the same name but the Broadway show is better than the book IMO as well. Plus the message of Wicked is a good one, a positive one, and everything is tied together. I wouldn't recommend the book.
The movie had a lot of cool visuals and it does tie things together but I thought it moved slow in a lot of places.