If you are planning on having your shrimp have babies, the betta will likely eat every last one unless you have an enormously heavily planted tank with tons of java moss, najas, and other such plants for the babies to hide in.I am considering getting a betta for my planted tank, but I need to know if they would eat shrimp. I would like to get some shrimp in the future but need to know if they would be compatible with a betta.
As for adults, it depends upon the individual personality of the betta. Some bettas see a shrimp and immediately go into attack mode; other bettas (such as the female betta I currently have) are perfectly fine with (adult) shrimp and don't show the slightest bit of aggression. So it really depends upon your individual betta.