is an Open Source strategy game which can be played online against other players, or in single player mode against AI opponents.
C JavaScript C++ Python PHP Lua Other
Pull request Compare This branch is 2273 commits behind freeciv:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.



This is yet another rewrite of the Freeciv web client, which
will make it possible to play Freeciv in your web browser.

This software is licensed under the GNU AFFERO GENERAL PUBLIC LICENSE.

Contact: Andreas Røsdal  -


The Freeciv Web client consists of these components:

* freeciv - a fork of the main Freeciv C client and server.

* freeciv-proxy - a HTTP proxy which allows web client users
  to connect to Freeciv civservers. This proxy converts C packets
  to and from JSON.

* freeciv-web - a Java web application for the Freeciv web client.
  This application is a AJAX application which consists of HTML,
  Javascript, images and JSP files which make up the application
  viewed in each user's web browser. 

* freeciv-img-extract - extracts the images of the Freeciv tileset,
  and generates a version for the web. This produces a tileset PNG 
  and Javascript. Run this to sync with the upstream Freeciv SVN 

* publite2 - a simple way to launch multiple civservers. 

* freeciv-music - contains music which can be played during the game.

System Requirements

- Resin 4.0.1 -

- Java 1.6.0 SDK -

- Python 2.7 -

- Mysql 5.0.x -

- Maven 2 -

- Probably some Linux distribution.

- Firefox

- Firebug for debugging -

- Closure Compiler -
  (Bundled in source code, no need to download.)

- curl-7.19.7 -

- OpenSSL -

- nginx 0.8.33 -

- simplejson 2.1.1 optional:

Compiling and running the Freeciv Web client

1. Install the system requirements. Install Resin in /opt/resin

2. Create mysql database called 'freecivmetaserver'
   Import mysql dump into a MySQL database from:  /publite2/mysqldump.sql.bz2

3. Build and configure freeciv-web. 

   - Edit /freeciv-web/src/main/webapp/freecivmetaserve/php_code/settings.php.dist,
     rename this file to settings.php, and update values for fcdb_username and fcdb_pw
     to your MySQL username and password.
   - Edit /freeciv-web/src/main/webapp/WEB-INF/resin-web.xml.dist, rename this
     file to resin-web.xml, and update the values for your MySQL database.
   - Run '' in the freeciv-web directory

4. Compile and install Freeciv. This involves running the following commands:
   cd freeciv 
   ./ --enable-client=no
   make install     (as root user)

5. Start resin with these commands:  
   cd /opt/resin/bin
   ./ start

6. Start publite2:
  Run in the publite2 directory.

7. Run the freeciv-proxy:
  Run in the freeciv-proxy directory.
 To debug, check the proxy debugging page: 

8. Start nginx on port 80 as root.

9. Start the web client in your browser:
   Point your web browser to http://localhost/

10. Continue to play the game. 

FIXME: Had to add -lssl when compiling server...

- create .awsAuth and change mode like this:  chmod 600 .awsAuth

Set ulimit -n 65535 in /etc/profile
and add some TCP/IP tuning in /etc/sysctrl.conf


- Make goto lines wrap in X direction of the map.
- Show city revolt graphics
- Show attack animation.
- Opera 11 broken in jQuery 1.5.x.
- WebGl?
- Port to Python 3.2
- Show borders
- Saving in the client side.
- Show city tile output in city dialog.
- Playback of games.
- HTML5 Web Sockets.