<p>A lot of <a href="http://www.slideshare.net/PyData/python-in-the-financial-industry-felix-fernandez" rel="nofollow">financial industry</a> prefers <a href="http://python.org/" rel="nofollow">Python</a>. Some remarkable Bitcoin exchanges, like Bitstamp and LocalBitcoins are built on the top of Python and <a href="https://www.djangoproject.com/" rel="nofollow">Django</a> web framework (though there exist other web frameworks you might want to use).</p>

<p>The reasons to choose Python include</p>

<ul>
<li><p>Open source ecosystem with a lot of modules to choose from, like <a href="https://github.com/vbuterin/pybitcointools" rel="nofollow">ones</a> for Bitcoin</p></li>
<li><p>It is not only web development language, but has large use base in scientific computing, making it ideal for data analysis and number crunching (see e.g. <a href="http://ipython.org/" rel="nofollow">IPython</a>, <a href="http://www.numpy.org/" rel="nofollow">NumPy</a> projects). This makes Python different from Ruby, which is more heavily web only.</p></li>
<li><p>Python applications have very good security track record, compared to e.g. PHP applications. To confirm this, see CVE entries to the programming language, related frameworks (<a href="http://www.cvedetails.com/product/18230/Python-Python.html?vendor_id=10210" rel="nofollow">Python</a>, <a href="http://www.cvedetails.com/product/128/PHP-PHP.html?vendor_id=74" rel="nofollow">PHP</a>)</p></li>
<li><p>Unlike more static languages, like Java and C#, which optimize CPU-bound performance, Python optimizes development time, making it very productive. You can always port your code to more heavy platform if your service grows popular and you have money to spend. This is especially important if your project is not backed up by a big corporation, but more startup oriented.</p></li>
</ul>

CC BY-SA 4.0
2018-09-25T18:32:05.517Z
Interesting because recently I read an article who quite says the opposite and was more for c++/java (8+). Unfortunately I couldn't find it to contribute here :-/
Anna Klein
CC BY-SA 3.0
2014-11-25T03:36:34.473Z
2014-11-25T03:36:34.473Z
Mikko Ohtamaa
<p>TL;DR I would use Scala, F# or Rust. If you don't like FP, then Java/C#. </p>

<p>Statically typed: The reason I would avoid Php, and most other dynamically typed languages, is to avoid bugs. Dynamically typed langs are easy to learn and code, but a statically typed lang like Java / C# will avoid a certain kind of bugs, and make refactoring easier.</p>

<p>Automatic memory management: I would also avoid langs where you manage memory, like C/C++, mostly because I fear bugs. Remember Heartbleed? That category of bugs can only happen when the programmer manages memory. Rust/Go are better.</p>

<p>Functional: I know that FP is considered hard, but it is a way to avoid bugs, especially if you are running a multithreaded app where the threads communicate with each other (like trading). FP's most important feature is that you work with immutable data structures. Functional langs are Haskell, F#, Scala and Erlang.</p>

CC BY-SA 3.0
2014-12-25T09:24:15.090Z
2014-12-25T09:24:15.090Z
olle kullberg
<p>Python is too slow for exchange job.
Some rates Python about five times slower than Java.
Java is not acceptable either.
Mostly for VM/GC and somehow dirty code practices often employed by Java developers.
C++ is gold standard for performance AND huge waste of time – tedious and long work required.
However, usually code is high quality as developers forced to clean after themselves. Apparently it enforces good practices after years of practice.
Then there are couple of exotic languages like Erlang and Go, would suit the requirements.
Erlang promises to screw your brains and waste a lot of time – see C++.
If you’ll get though of it  - results might be good.
Go seems to be the simplest choice specifically tailored for parallel processing.
Not sure if it fits to financial application needs.</p>

CC BY-SA 4.0
2018-09-25T18:36:03.753Z
Please provide sources for your claims.
Anna Klein
CC BY-SA 3.0
2017-08-26T18:05:55.457Z
2017-08-26T18:05:55.457Z
geronimo
<p>Checking the partial UI rendered pages for </p>

<p>Cryptsy it seems they are using jquery, bootstrap </p>

<p>coinsquare is using fast-cgi, Angularjs, Angularjs</p>

<p>coinsetter seems to be using Java, jquery, bootstrap.js </p>

<p>Mtgox famously used PHP </p>

<p>Javascript farmework 1.Angularjs 2. Nodejs 3.Phython 4.ruby on rails.</p>

<p>It really depends upon the skill your team have or is willing to learn.</p>

<p>Building a thin client over HTML5, Angularjs, bootstrap,  nodejs, Java are common denominator among many exchanges.</p>

CC BY-SA 3.0
2014-11-23T16:14:21.083Z
I'm confused - how did you arrive at this information?
Nick ODell
CC BY-SA 3.0
2014-11-25T22:58:55.083Z
Looking at the client side libraries and talking to some of the developers. Also looking at the skills the companies have been hiring.
digitizedcurrencynow
CC BY-SA 3.0
2014-11-23T07:56:32.743Z
2014-11-23T16:13:48.147Z
2014-11-23T16:13:48.147Z
digitizedcurrencynow
<p>I've only heard PHP is terrible (e.g. in the context of Mt. Gox) and a more efficient/more security-oriented language would be preferable for matching orders and account security. Which programming language, and due to what reasons, would be better?</p>

CC BY-SA 3.0
2014-11-20T06:44:21.807Z
It's what you do with it that counts :) PHP isn't terrible, but it's not the right tool for an exchange back-end. I know some use C/C++.. I suspect most do.. for speed/efficiency and code quality.
George
CC BY-SA 3.0
2014-11-20T16:53:42.673Z
@George, take a look at http://meta.bitcoin.stackexchange.com/questions/633/please-post-answers-as-answers-not-as-comments?cb=1.
morsecoder
CC BY-SA 3.0
2014-11-20T17:47:51.077Z
fair enough. I didn't think it quite warranted being a full answer as I don't actually know what most exchanges use so it was more of a comment than an answer.
George
CC BY-SA 3.0
2014-11-23T13:28:10.167Z
Hey new_to_bitcoin, it seemed to me that your underlying question was rather to ask a best-practice recommendation and reasoning, than just an iteration of the status quo. I've thusly edited your question. If you feel that it's not what you wanted to ask anymore, feel free to rollback or further modify. For a short intro how our site works, check out [tour] and [ask].
Murch
<exchanges><development>
What programming language should be used to develop Bitcoin exchange software? Why?
new_to_bitcoin
# What programming language should be used to develop Bitcoin exchange software? Why?

(Asked by: username_0 on 2014-11-20)

I've only heard PHP is terrible (e.g. in the context of Mt. Gox) and a more efficient/more security-oriented language would be preferable for matching orders and account security. Which programming language, and due to what reasons, would be better?

**Tags:** exchanges, development

> **Comments:**
> **username_1**: It's what you do with it that counts :) PHP isn't terrible, but it's not the right tool for an exchange back-end. I know some use C/C++.. I suspect most do.. for speed/efficiency and code quality.  
> **username_2**: @username_1, take a look at http://meta.bitcoin.stackexchange.com/questions/633/please-post-answers-as-answers-not-as-comments?cb=1.  
> **username_1**: fair enough. I didn't think it quite warranted being a full answer as I don't actually know what most exchanges use so it was more of a comment than an answer.  
> **username_3**: Hey username_0, it seemed to me that your underlying question was rather to ask a best-practice recommendation and reasoning, than just an iteration of the status quo. I've thusly edited your question. If you feel that it's not what you wanted to ask anymore, feel free to rollback or further modify. For a short intro how our site works, check out [tour] and [ask].  

---

## 4 answers

### Answer by username_4 on 2014-11-25. Score: 2

A lot of [financial industry](http://www.slideshare.net/PyData/python-in-the-financial-industry-felix-fernandez) prefers [Python](http://python.org/). Some remarkable Bitcoin exchanges, like Bitstamp and LocalBitcoins are built on the top of Python and [Django](https://www.djangoproject.com/) web framework (though there exist other web frameworks you might want to use).

The reasons to choose Python include

* Open source ecosystem with a lot of modules to choose from, like [ones](https://github.com/vbuterin/pybitcointools) for Bitcoin
* It is not only web development language, but has large use base in scientific computing, making it ideal for data analysis and number crunching (see e.g. [IPython](http://ipython.org/), [NumPy](http://www.numpy.org/) projects). This makes Python different from Ruby, which is more heavily web only.
* Python applications have very good security track record, compared to e.g. PHP applications. To confirm this, see CVE entries to the programming language, related frameworks ([Python](http://www.cvedetails.com/product/18230/Python-Python.html?vendor_id=10210), [PHP](http://www.cvedetails.com/product/128/PHP-PHP.html?vendor_id=74))
* Unlike more static languages, like Java and C#, which optimize CPU-bound performance, Python optimizes development time, making it very productive. You can always port your code to more heavy platform if your service grows popular and you have money to spend. This is especially important if your project is not backed up by a big corporation, but more startup oriented.

> **Comments:**
> **username_5**: Interesting because recently I read an article who quite says the opposite and was more for c++/java (8+). Unfortunately I couldn't find it to contribute here :-/  

---

### Answer by username_6 on 2014-12-25. Score: 1

TL;DR I would use Scala, F# or Rust. If you don't like FP, then Java/C#.

Statically typed: The reason I would avoid Php, and most other dynamically typed languages, is to avoid bugs. Dynamically typed langs are easy to learn and code, but a statically typed lang like Java / C# will avoid a certain kind of bugs, and make refactoring easier.

Automatic memory management: I would also avoid langs where you manage memory, like C/C++, mostly because I fear bugs. Remember Heartbleed? That category of bugs can only happen when the programmer manages memory. Rust/Go are better.

Functional: I know that FP is considered hard, but it is a way to avoid bugs, especially if you are running a multithreaded app where the threads communicate with each other (like trading). FP's most important feature is that you work with immutable data structures. Functional langs are Haskell, F#, Scala and Erlang.


---

### Answer by username_7 on 2017-08-26. Score: 0

Python is too slow for exchange job.
Some rates Python about five times slower than Java.
Java is not acceptable either.
Mostly for VM/GC and somehow dirty code practices often employed by Java developers.
C++ is gold standard for performance AND huge waste of time – tedious and long work required.
However, usually code is high quality as developers forced to clean after themselves. Apparently it enforces good practices after years of practice.
Then there are couple of exotic languages like Erlang and Go, would suit the requirements.
Erlang promises to screw your brains and waste a lot of time – see C++.
If you’ll get though of it - results might be good.
Go seems to be the simplest choice specifically tailored for parallel processing.
Not sure if it fits to financial application needs.

> **Comments:**
> **username_5**: Please provide sources for your claims.  

---

### Answer by username_8 on 2014-11-23. Score: -1

Checking the partial UI rendered pages for

Cryptsy it seems they are using jquery, bootstrap

coinsquare is using fast-cgi, Angularjs, Angularjs

coinsetter seems to be using Java, jquery, bootstrap.js

Mtgox famously used PHP

Javascript farmework 1.Angularjs 2. Nodejs 3.Phython 4.ruby on rails.

It really depends upon the skill your team have or is willing to learn.

Building a thin client over HTML5, Angularjs, bootstrap, nodejs, Java are common denominator among many exchanges.

> **Comments:**
> **username_9**: I'm confused - how did you arrive at this information?  
> **username_8**: Looking at the client side libraries and talking to some of the developers. Also looking at the skills the companies have been hiring.  

---

