In Spore, you can create an alliance with any other creature, tribe, civilization or empire once you have a reach a green smiley relationship with that creature, tribe, civilization or empire. In most cases, alliances can not be revoked.
See: Relation bonus for more information.
Your only allies are simply just other cells of your kind; cells of other types will hunt/ignore your cell.
In Creature Stage, you can ally with another species by befriending 3 members of the species. You can befriend them by singing, dancing, posing or charming. Allied species can join your hunt pack, and you can also heal at their nests. If you befriend an Alpha Creature, you unlock a new part. Be careful though, most carnivores start out disliking your species, although usually, they have low social skills. Many other species will automatically be Innately hostile towards you on hard mode.
You can also, by having strong social skills and pack members, befriend rogue creatures. You only need to socialize one time (sometimes two) with the Rogue to ally it. Rogues are extremely powerful (Only epic creatures are stronger), and to most players they are very valuable.
Occasionally there is a glitch, where, if you befriend a species who originally had an orange angry face with you (usually just hostile), it may attack you. This occurs when you do not befriend all members at a nest. This causes all members of the species to be angry with you. The species will still be your ally, displayed with a green happy face on the minimap, but will chase and try to kill you, Beware! If you have unlocked the skill Siren Song by completing the cell stage as a herbivore you can attempt to ally with hostile animals, making hard mode a lot easier. And there is Another glitch where sometimes if you meet a Unevolved Creature that has a orange face and then you meet the Evolved creation of that creature and you befriend them Sometimes it will say the unevolved creature's nest which has a orange face is your ally on the minimap.And It also lets you heal at their nest
During the Tribal Stage, you must play music for other tribes at least twice in order to ally with that tribe (Or only once if you impress them to the "Friendly" stage using the fireworks ability if you have it.). Use the Maracas, Wooden horns, or Didgeridoos to do this. Sometimes you may need to bring a gift (needs at least 10 food) before that if they dislike or hate you normally. Allied tribes will constantly bring gifts to you, and your relationship with them won't decrease as time passes, however, attacking them via firebombs or other non-direct attacks will lower your relationship. Also, if members of an allied tribe happen to be in the immediate vicinity of a battle they may fight alongside you.
In the Civilization Stage, giving gifts and complimenting a civilization are the simplest ways to raise your relationship. However, while taking over an civilization, you may see your relationship with another civilization quickly rise. That is because you fought their enemy, which gives a large sum of alliance relation with that civilization. Also, buying their city for a generous sum will make them more friendly with you as well as granting you control of the city.
Through allies, you can ask them to attack other civilizations, and at the end of the game, they will ask you if they can join your empire. This is called a Diplomatic Takeover, and is a simple way to expand towards the end, if you do not want to use a superweapon like ICBM or Global Merger. It also makes it much easier to get the Fear of Flying achievement.
There are lots of ways to be awarded a green smiley relationship. Those ways are to bring gifts (the higher the amount of Sporebucks, the better), do missions, agree to help that empire, trade, use the Happy Ray, place an Embassy on one of their planets, making a generous offer to buy their star system, terraform one or more of their planets, and defend them from Eco Disasters and attacks. Also you can get a friendship advantage by evolving sentient species using a Monolith
Through allies, you can add new ships to your Space Fleet and you can have them help you conquer an enemy empire. They can also teach you their philosophy. Allying with them also speeds up your progress in the Body Guard, Diplomat, Trader, Economist, Zoologist, Missionista and Eco Hero Badges.
However there are lots of ways to make other empires unhappy with you. The most common way is refusing to give them money when they demand you for it or by attacking their cities or ships. There are several other ways such as befriending the Grox , which makes all other space empires hate you (not including your own) and "breaking the galactic code" which is triggered by using gadgets such as the Planet buster or using super weapons like the Zealot's Fanatical Frenzy or the Scientist's Gravitation Wave.