Rules of the shogi.

Objective
The objective is to capture your opponent's king.

Game equipment
Two players, Sente and Gote (or Black and White ), play on a board composed of squares in a grid of 9 ranks (rows) by 9 files (columns). The squares are undifferentiated by marking or colour.
Each player has a set of 20 wedge-shaped pieces, of slightly different sizes. From largest to smallest (most to least powerful) they are:
1 king
1 rook
1 bishop
2 gold generals
2 silver generals
2 knights
2 lances
9 pawns
Most of the English-language names are chosen to correspond to their rough equivalents in Western chess, not necessarily as translations of the Japanese names.
Each piece has its name in the form of two Japanese characters marked on its face. On the reverse side of each piece (other than kings and gold generals) are one or two other characters, often in a different colour (e.g., red instead of black); this reverse side is used to indicate that the piece has been promoted during play. The pieces of the two sides do not differ in colour, but instead each piece is shaped like a wedge, and faces forward, toward the opposing side. This shows who controls the piece during play. See Shogi Pieces and Symbols for pictures of the pieces, both normal and promoted.
Many people who are not familiar with Chinese characters have been deterred from learning shogi due to the perceived difficulty of learning the characters used on the pieces. This has led to the development of "Westernized" (or "international") pieces, which replace the characters with more intuitive symbols, such as pictorial icons. However, perhaps because the traditional pieces are iconic by size, with more powerful pieces being larger, most players soon learn to recognize them, and Westernized pieces have never become popular.

Here is a table of the pieces, with their Japanese representation:

English name Image Kanji Japanese pronunciation
Meaning Abbreviations
King
(reigning)
王将 osho royal general o
King
(challenging)
玉将 gyokusho jeweled general gyoku
Rook 飛車 hisha flying chariot hi
Promoted rook
("Dragon")
龍王 ryuo dragon king 龍 or 竜 ryu
Bishop 角行 kakugyo angle mover kaku
Promoted bishop
("Horse")
龍馬 ryuma swift horse uma
Gold general
("Gold")
金将 kinsho gold general kin
Silver general
("Silver")
銀将 ginsho silver general gin
Promoted silver 成銀 narigin promoted silver (全)  
Knight 桂馬 keima laureled horse kei
Promoted knight 成桂 narikei promoted laurel (圭 )   
Lance 香車 ky?sha incense chariot kyo
Promoted lance 成香 narikyo promoted incense (杏 )   
Pawn 歩兵 fuhyo foot soldier fu
Promoted pawn
("tokin")
と金 tokin reaches gold to

English speakers sometimes refer to promoted bishops as horses and promoted rooks as dragons, after their Japanese names, and generally use the Japanese name tokin for promoted pawns. Silver generals and gold generals are commonly referred to simply as silvers and golds.
The characters inscribed on the backs of the pieces to indicate promoted rank may be in red ink, and are usually cursive. The characters on the backs of the pieces that promote to gold generals are cursive versions of 金 'gold', becoming more cursive (more abbreviated) as the value of the original piece decreases. These abbreviated characters have these equivalents in print: 全 for promoted silver, 今 for promoted knight, 仝 for promoted lance, and 个 for promoted pawn (tokin). Another convention has abbreviated versions of the original characters, with a reduced number of strokes: 圭 for promoted knight, 杏 for promoted lance, with promoted silver the same 全 as above, and と for tokin.

Setup

The starting setup of a game of shogi, from the perspective of Black.
Each side places his pieces in the positions shown below, pointing toward the opponent.
In the rank nearest the player:
The king is placed in the center file.
The two gold generals are placed in the adjacent files to the king.
The two silver generals are placed adjacent to each gold general.
The two knights are placed adjacent to each silver general.
The two lances are placed in the corners, adjacent to each knight.
That is, the first rank is |L|N|S|G|K|G|S|N|L|.
In the second rank, each player places:
The bishop in the same file as the knight on the player's left.
The rook in the same file as the knight on the player's right.
In the third rank, the nine pawns are placed one in each file.
Traditionally, even the order of placing the pieces on the board is determined. There are two recognized orders: Ohashi and ito. Shogi Pineapple indicates the order (page is in Japanese); ohashi is depicted on the left and ito on the right.

Game play
The players alternate making a move, with Black moving first. (The traditional terms 'black' and 'white' are used to differentiate the sides during discussion of the game, but are not literally correct.) A move consists of moving a piece on the board and optionally promoting the piece, or dropping a captured piece onto an empty square of the board. Each of these options is detailed below.

Movement and capture
Each piece moves in a distinct way. The kings, generals, and pawns only move one square at a time. If an opponent's piece occupies a square that is a possible destination for the moving piece, the opponent's piece may be captured by placing the moving piece on that square, and removing the opponent's piece from the board. If a friendly piece (that is, a piece controlled by the same player) occupies the square, the moving piece may not move in that direction.
The knight jumps, that is, it moves over any intervening piece, whether friend or foe. It is the only piece that can do this.
The lance, bishop, and rook can potentially move any number of squares along a straight line, limited by the edge of the board. If an opponent's piece intervenes, it may be captured by moving to that square, and removing it from the board. If a friendly piece intervenes, the moving piece is limited to a distance that stop short of the intervening piece; if the friendly piece is adjacent, it may not move in that direction at all.
Pieces move either orthogonally (that is, forward, backward, or to the side, in the direction of one of the arms of a plus sign, +), or diagonally (in the direction of one of the arms of a multiplication sign, ×). Again, the knight is an exception.

King
A king can move one square in any direction, orthogonal or diagonal.

Gold general
A gold general can move one square orthogonally, or one square diagonally forward, giving it six possibilities. It cannot move diagonally backward.

Silver general
A silver general can move one square diagonally or one square straight forward, giving it five possibilities.
Because an unpromoted silver can retreat more easily than a promoted one (see below), it is very common to leave a silver unpromoted at the far side of the board. A silver is never required to promote.

Knight
A knight jumps at a an angle intermediate between orthogonal and diagonal, amounting to one square forward plus one square diagonally forward, in a single motion. That is, it has a choice of two forward destinations. It cannot move to the sides or backwards.
The knight is the only piece that ignores intervening pieces on the way to its destination, though its destination square must of course be either empty, or occupied by an opponent's piece (in which case the opponent's piece is captured), just as with any other moving piece.
It is often useful to leave a knight unpromoted (see below) at the far side of the board. However, since a knight cannot move backward or to the sides, it must promote when it lands on one of the two farthest ranks.

Lance
A lance can move any number of free squares forward. It cannot move backward or to the sides.
It is often useful to leave a lance unpromoted (see below) at the far side of the board. However, since a lance cannot move backward or to the sides, it must promote when it lands on the farthest rank.

Bishop
A bishop can move any number of free squares in the four diagonal directions.
Because it cannot move orthogonally, an unpromoted bishop can only reach half the squares on the board.

Rook
A rook can move any number of free squares in the four orthogonal directions.

Pawn
A pawn can move one square forward. It cannot retreat.
Since a pawn cannot move backward or to the sides, it must promote (see below) when it moves to the farthest rank. However, in practice, a pawn is promoted whenever possible.
There are restrictive rules for where a pawn may be dropped (see below).

Promotion
A player's promotion zone consists of the three farthest ranks, at the original line of the opponent's pawns and beyond (that is, the opponent's territory at setup). If a piece crosses the board within the promotion zone, including moves into, out of, or wholy within the zone, but not including drops (see below), then that player may choose to promote the piece at the end of the turn. Promotion is indicated by turning the piece over after it moves, revealing the character for the promoted piece.
Promoting a piece has the effect of changing how that piece moves until it is removed from the board. Each piece promotes as follows:
A king or a gold general cannot promote, nor can pieces which are already promoted.
A silver general, knight, lance or pawn, when promoted, loses its normal movement and gains the movement of a gold general.
A bishop or rook, when promoted, keeps its normal movement and gains the ability to move one square in any direction (like a king). This means the bishop is now able to reach any square on the board, given enough moves.
If a pawn, knight or lance reaches the furthest rank, it must be promoted, since it would otherwise have no legal move on subsequent turns. For the same reason, a knight reaching the penultimate rank must be promoted.
When captured, pieces lose their promoted status.

Drops
Captured pieces are truly captured in shogi. They are retained "in hand", and can be brought back into play under the capturing player's control. On any turn, instead of moving a piece across the board, a player can take a piece he has previously captured and place it on any empty square, facing the opponent. The piece is now part of the forces controlled by that player. This is termed dropping the piece, or just a drop.
A drop cannot capture a piece; that requires an additional move.
Pieces that are dropped in the promotion zone do not promote as a result: Promotion requires that piece make a normal movement on a subsequent turn, as detailed under "Promotion", above. Pieces that are promoted when captured lose that promotion; they are unpromoted when dropped back on the board.
A pawn, knight, or lance may not be dropped on the furthest rank, since it would have no legal move on subsequent turns. Similarly, a knight may not be dropped on the penultimate rank.
There are two restrictions when dropping pawns:
A pawn cannot be dropped into the same file (vertical column) as another unpromoted pawn controlled by the same player. (A tokin, or promoted pawn, does not count as a pawn when considering this drop retriction.) A player who has an unpromoted pawn on every file is therefore unable to drop a pawn anywhere. For this reason, it is common to sacrifice a pawn in order to gain flexibility for drops.
A pawn cannot be dropped directly in front of the opponent's king, if the opponent would have no way to prevent his king being captured on the next move. In other words, a pawn cannot be dropped to give immediate mate.
It is very common for players to swap bishops, which face each other across the board. This leaves each player with a bishop "in hand" to be dropped later, and gives an advantage to the player with the stronger defensive position.

Check and mate
When a player makes a move such that the opponent's king could be captured on the following move, the move is said to give check to the king; the king is said to be in check. If a player's king is in check and no legal move by that player will get the king out of check, the checking move is also a mate, and effectively wins the game.
A player is not allowed to give perpetual check.

Game end
A player who captures the opponent's king wins the game. In practice this rarely happens; a player will resign when loss is inevitable and the king will be taken on the opponent's next move (as in International Chess) because of the tradition that it is seen as an embarrassment to lose.
A player who makes an illegal move loses immediately. (This rule may be relaxed in casual games.)
There are two other possible (but fairly uncommon) ways for a game to end: repetition (sennichite) and impasse (jishogi).
If the same position occurs four times with the same player to play, then the game is no contest. (Recall, however, the prohibition against perpetual check.) For two positions to be considered the same, the pieces in hand must be the same, as well as the position on the board.
The game reaches an impasse if both kings have advanced into their respective promotion zones and neither player can hope to mate the other or to gain any further material. If this happens then the winner is decided as follows: each rook or bishop scores 5 points for the owning player, and all other pieces (except kings) score 1 point each. Promotions are ignored for the purposes of scoring. A player scoring less than 24 points loses. If both players have at least 24 points, then the game is no contest.
Games which are no contest are usually counted as draws in amateur tournaments, but in professional tournaments the rules typically require the game to be replayed with colours reversed (possibly with reduced time limits).

Handicaps
Games between players of disparate strength are often played with handicaps. In a handicap game, one or more of White's pieces is removed before the start of play, and White plays the first move of the game. Note that the pieces removed at the beginning play no further part in the game - they are not available for drops. The imbalance created by this method of handicapping is not as strong as it is in chess, because material advantage is not as powerful in shogi as in chess.
Common handicaps, in increasing order of size, are as follows:
Lance: remove White's left lance
Bishop: remove White's bishop
Rook: remove White's rook
Rook and lance: remove White's rook and left lance
Two pieces: remove White's rook and bishop
Four pieces: remove White's rook, bishop and both lances
Six pieces: remove White's rook, bishop, both lances and both knights
Other handicaps are also occasionally used. The relationship between handicaps and differences in rank is not universally agreed upon; several different systems are in use.