From Bulbapedia, the community-driven Pokémon encyclopedia.
Wild Pokémon (Japanese: 野生ポケモン wild Pokémon) are any Pokémon that are not currently owned by a Pokémon Trainer. They are encountered in most parts of the Pokémon world, most commonly outside of cities and towns, often in tall grass, in caves, or on water. Typically, a Trainer will attempt to capture a wild Pokémon with a Poké Ball but it is also common for a trainer to run from a Pokémon they are not interested in. There are many instances of wild Pokémon being used for assistance without being caught, such as Pokémon Rangers using them to perform a task by directing them with a Capture Styler.
In the games
In the games, wild Pokémon will appear to the player in a variety of locations, most often by walking through tall grass, but also within caves, abandoned buildings, surfing on water, fishing, smashing rocks, headbutting small trees, using Sweet Scent, or by slathering honey on certain trees. Depending on the location, the Pokémon may be different species, and are typically at higher levels in areas only accessible later in the game.
When encountered, a wild Pokémon's moveset will consist of the most recent four moves its species learns by level-up: that is to say, a level 8 Yanma will know Tackle, Foresight, and Quick Attack when encountered in the wild in Pokémon Platinum, while one encountered at level 19 will have Quick Attack, Double Team, SonicBoom, and Detect. This is true for even evolved species, such as Raichu, which, if it were able to be encountered in the wild, would always know ThunderShock, Tail Whip, Quick Attack, and Thunderbolt.
There are several ways to alter the wild Pokémon encounter rate. One of these, introduced in Generation I, is the use of Repel, which will avoid encounters with any Pokémon of a lower level than the party's lead Pokémon. In Generation II, Pokémon March and Pokémon Lullaby, played on the Pokégear, will raise or lower the encounter rate respectively, while certain abilities and the White and Black Flutes do the same in Generation III and Generation IV.
In some instances, two wild Pokémon will appear at once. In Generation IV, this occurs when the player travels in a specific region with another Pokémon Trainer. They battle in the double battle method introduced in the third generation. In Generation V, there is the chance of two Pokémon appearing at once in some locations. In both instances, one of the Pokémon will have to be defeated before the other can be caught.
In the anime
Typically, wild Pokémon are not a central feature of the anime, which focuses mostly on the Pokémon belonging to Ash and his friends and other trainers he encounters. Most of the Pokémon belonging to the group were shown in the wild at some point, but are usually captured at a later point in the same episode, most often at the end. Despite this, there have been several recurring wild Pokémon who appear over a length of time and are not captured. Of all of these Pokémon, only an Aipom that stole Ash's hat went on to be captured several episodes after it appeared.
There are however numerous examples of wild Pokemon being featured in the anime in debut episodes that introduce their species, such as Clefairy in Clefairy and the Moon Stone and Sudowoodo in Type Casting.
In the first anime episode, Ash's Pokédex states that wild Pokémon tend to be jealous of human-trained Pokémon, this being one of the reasons that the Spearow Ash hit with a rock attacked Pikachu instead.
In the manga
As Pokédexes prior to the arcs in Hoenn typically needed the Pokémon to be captured in order for data to be gained, capturing wild Pokémon has been a long-standing point for every Pokédex Holder save Gold and Silver until the Ruby & Sapphire chapter. The first wild Pokémon to be captured was a wild Nidorino by Red, and even legendary Pokémon were seen as soon as the first round, though the one in question (a Mew appearing near Pallet Town) was not captured. Pokémon that have been released, unlike in the games, do sometimes appear in the wild and can be re-caught or controlled by another Trainer, such as Emerald's Sceptile and Mewtwo, and again unlike in the games, where identical Trainer ID means that high-level Pokémon can be controlled by its Trainer, several Pokémon such as Pika and Buizel were disobedient and likely to even attack its Trainer on a whim.