Solvitaire - The solitaire solver  cards
Introduction to Solvitaire

Solvitaire is a Windows application for playing and solving the card game called solitaire (or sometimes patience).

It gives you the choice of

choosemode

Solving games from Microsoft Solitaire Collection

Solvitaire can read Microsoft Solitaire Collection games from the screen and use the keyboard and mouse to play through them for you. This means that, as well as clearing boards, it can also find the best solution for removing cards or stacks or achieving a certain score within a certain number of moves. It does this by reading the cards from the screen and playing through the game to expose unknown cards and then running through solutions to achieve the objective.

You no longer need to be stuck on one of the Daily Challenges, Events or Star Club challenges.

Solvitaire can also save the solutions to a file and then play these solutions back quickly. This is how the solitaire bots get into the top 100 leaderboard. You will occasionally see SolvitaireBot at the top of the board, if we happen to be running speed tests of Solvitaire using this technique.

Read games in from file

If you have a card deck from some other source then you can give Solvitaire a file containing those cards (identifying the cards as Ks, Qh, Jd, 10c and so on). Solvitaire can then find a solution for you. If there are cards that you have not yet exposed then enter these as "??" and Solvitaire will give you a play sequence you can use to expose one of these unknown cards.

Play Solitaire

You can choose to just play a game of solitaire. If you choose this option then you will be asked for the type of game and the level of difficulty. At any time during your game play, you can ask Solvitaire to show you a set of moves you could make to solve the game from that point. This is not just a simple "hint", what you get is a full solution to the game you are playing, starting from the point you have reached

If there are no possible solutions from that point then Solvitaire will tell you that you must back out some moves and try again. Why waste time trying to find a solution when there are no solutions to be found?

You can run the free version of Solvitaire for 30 days. After that, if you so wish, you can purchase an unlimited license for a small fee.

If you have read enough and want to try it out then just

The sections below give more detailed information about the product.

Solving Games from Microsoft Solitaire Collection
pausedState

Before using Solvitaire to solve games from Microsoft Solitaire Collection you obviously have to install Microsoft Solitaire Collection on your PC. You can download it from the Microsoft Store or from www.xbox.com (NOT the web version from msn.com)

Go through the initial setup and get Microsoft Solitaire to the point where the cards have been dealt out at the start of a game. Then load up Solvitaire and it will enter the paused state, as shown in the screenshot.

Simply click on the Start button solvebutton to start the game, or choose one of the specific challenges from the Start menu.

If at any point you move the mouse, or press the Esc key, then Solvitaire will stop moving cards around and enter the paused state once more. It will also enter the paused state if a window pops up unexpectedly.

The user interface for Microsoft Solitaire Collection mode
samplegame

The user interface shows the current game state. At the top of the window are icons representing the cards.

cardunread Initially the card state has not been determined and all cards are represented as gray icons.
cardunknown Cards that are face down are initially marked as blue, "unknown".
cardhunting During game play the next face down card that will be turned up is highlighted in orange.
cardknown Once a card is exposed and the suit/value determined then it is displayed as green.

The control buttons
controlbuttons

All the play modes use the same set of buttons to control play.

The Start solvebutton startbutton Step stepbutton Pause pausebutton and Undo undobutton buttons allow you to run, single step, pause running and undo the game being played.

The start button may be either a question mark or a run icon depending on whether Solvitaire is waiting to solve a game or is playing through a game.

The status icon
controlbuttons

The final button within the control panel is a status icon. This shows the current game state as follows.

analyze The initial state is the analysis of the deal to determine the variant of solitaire, to read the dealt cards and to skim through the deck.

gears Once the deal has been analyzed, Solvitaire moves on to calculating a solution.

prize In the variants where all cards are known immediately following the analysis (Freecell and Pyramid) the solution is presented as soon as the calculation is complete. The success icon identifies this.

walker Some variants are dealt with cards that are face-down and Solvitaire must play to expose them. This is the slow part of solving a game and the walker icon illustrates this.

spinner It is unlikely that Solvitaire will be able to play through a game without some backing out of moves. This is shown by the backward rotating spinner.

pause The pause icon indicates Solvitaire is paused. The status text indicates what triggered the pause. Click on the Start button to resume play.

More status information is available through the progress bars.

progressbars

The progress bars give more detail on the current state of play. See the FAQ section "How does it work" for an explanation.

Starting in the middle of a game
inprogress

If you launch Solvitaire when cards have already been played then it will first ask to back out to the start of the game.

It has to do this in order to be able to determine the solitaire variant, and to read the initial state of the cards.

Switching between different types of solitaire game

Solvitaire detects the type of game by inspecting the initial card layout. To run with a different type of game, just

Running a game from file

You can run a game from a particular deal that is defined in a text file. The file must identify the solitaire variety and define the layout for a full deck (or two decks) of cards, with each card defined by a value a,k,q,j,10,9...2 and a suit s,h,d,c. The stacks must come first followed by the remainder of the pack.

The card reader is case insensitive. There can be spaces between the cards (kd ,ah , qs,) but no spaces between each line. If you are trying to discover an unknown card value then you can use ?? as the unknown card placeholder. Solvitaire will solve until it hits one of the cards marked as ?? and give you the sequence of moves to expose that card.

The first card in the list for the pack is the first one that is dealt (so for a Klondike 3 card deal the third card in the list will be at the top of the pile after the first deal).

Here are working examples of the file layout for each variety.

Play Solitaire

If you choose to play a game then you are asked what type of game you want to play.

choosegame

The game chooser dialog lets you choose the solitaire variation, including the number of cards dealt in Klondike and the number of suits to play in Spider. It also has a selection for the degree of difficulty of the game.

Games are generated using a random card generator that takes a "seed" to determine the card sequence. (The same approach that Microsoft uses to generate the cards in Solitaire Collection Freecell). Solvitaire has worked through the first 10,000 seeds for each game and assigned difficulties based on the effort taken to solve each one.

All the easy/average/hard games are guaranteed to be soluble. If you enter your own random number as a seed then there is no guarantee that the cards will be soluble. If you want to replay a game then choose Specific game # and leave the seed unchanged and you will find you are replaying the last game you played.