
Ask HN: Django hosting recommendations? - ryanx435
Hey everyone. I&#x27;ve been looking for a webhost that allows me to run a Django app but ALSO has an email server that allows for my employees to have their  work email on. The django app will also need the ability to connect to the email server to send account registration emails.<p>I really like heroku, but they don&#x27;t have email hosting as an option.
Hostgator has email hosting, but doesn&#x27;t allow django apps.<p>any recommendations?<p>thank you
======
pdeuchler
> The django app will also need the ability to connect to the email server to
> send account registration emails

Beyond the technical/architectural issues others have brought up, you should
not be mixing transactional email with work email for a business. Use a
transactional provider like Sendgrid/Mailgun/Mailchimp to manage your
registration messages, and run the employee email through something entirely
different (a separate server or GApps). It's only a matter of time before
someone marks someone's sales email as spam and you end up not being able to
send registration emails because Spamhaus has blacklisted your IP.

This might make your solution easier, as you can use an email addon with
Heroku for transactional, and then get to choose whatever host you want for
employee mail without having to be constrained by needing Django hosting as
well.

~~~
medmunds
> you should not be mixing transactional email with work email

Can't emphasize that enough.

Django makes it easy to substitute email backends [1], and there are backends
available for most transactional ESPs. I maintain one that covers several
popular, full-featured ESPs [2]; a quick search of PyPI will also turn up
backends for AWS-SES and others.

[1]:
[https://docs.djangoproject.com/en/1.11/topics/email/#email-b...](https://docs.djangoproject.com/en/1.11/topics/email/#email-
backends) [2]: [https://github.com/anymail/django-
anymail](https://github.com/anymail/django-anymail)

------
tga
You're limiting your options by insisting to have both app and email hosting
with the same company. My suggestion is to investigate them separately.

For app hosting, fire and forget (Heroku, Amazon Elastic Beanstalk), shared
hosting (like Webfaction and many others), VPS/dedicated server (like AWS EC2,
Digital Ocean and many others).

Managed options will take a lot less effort and knowhow to keep a production
app running, but cost more. Your own server (VPS) will get you more resources
for the same price, but you'll have to configure and maintain everything
yourself (app server, static files, database, load balancing, backups and
recovery, monitoring, upgrades, security, performance, scaling, etc).

For company email, Office 365, Google G Suite, Rackspace Mail. Maybe Amazon
WorkMail (I only know it exists).

Edit: I misunderstood that you're looking for email _service_. If you want to
run your mail server yourself, you need 1) a computer you control
(VPS/dedicated) and 2) to know what you're doing. Unless you have a good
reason to do that, I suggest you outsource it and get on with your business.

~~~
VT_Drew
>You're limiting your options by insisting to have both app and email hosting
with the same company. My suggestion is to investigate them separately.

Even if you do have them with the same company you should have them installed
on separate VPS. Sounds like OP wants it all on one server, which I would
advise against.

------
shanecleveland
I've always been happy with
[https://www.webfaction.com](https://www.webfaction.com). Includes one-click
installer for Django. Webmail options are basic. But they are an option, or
users could receive mail through an email client. But I would also recommend
forwarding mail services to
[https://www.fastmail.com](https://www.fastmail.com).

~~~
jgalt212
webfaction is good, but no matter how much money you pay them they don't offer
a phone or chat support. That's why we moved away from them. Otherwise, I
think they are very good.

~~~
shanecleveland
That's a fair knock. Email support system has been pretty good, though. At
least very knowledgable support staff. But I can see where more would nice,
particularly if paying at a certain level.

------
rogerhoward
Don't combine the two; outsource your email hosting (Google, etc) to save a
lot of pain, and select your Django hosting from a large range of options,
from Digital Ocean to Heroku to AWS.

No technical reason these two need to be hosted together, and the market has
definitely not favored putting all these eggs in one provider.

~~~
VT_Drew
>Don't combine the two

>No technical reason these two need to be hosted together

Sound advice. To me it sounds like maybe the OP wants both on the same VPS,
which is a horrible idea. Even if you found one provider, still you should
have separate VPS's for the email and Django app.

------
nachtigall
Gandi Simple Hosting for python plus DB starts at 4 bucks a month and comes
together with Mail and a Varnish cache:
[https://www.gandi.net/hosting/simple?language=python&db=mysq...](https://www.gandi.net/hosting/simple?language=python&db=mysql)
8 €/$ if you need https.

~~~
kennydude
Did not know these guys did Python hosting. Thanks for posting!

------
sixhobbits
I used Zappa[0] and AWS Lambda to host a Flask application recently. After
years of deploying Flask applications to VPSs behind Apache, I was pretty
impressed by how simple it was to deploy a serverless app. Nice that there's
no need to worry about security patches, OS updates, HTTPS cert renewals, etc.
And so far it's waay cheaper for my usage too. If your Django app doesn't have
too many dependencies, it might be worth considering. Then you can use AWS
Simple Email Service (or any of the many third-party services already
recommended) for the email needs.

[0] [https://github.com/Miserlou/Zappa](https://github.com/Miserlou/Zappa)

------
27182818284
I've used a couple sources in the past including Heroku.

I found Heroku at the time (this was more than two years ago) to be an
adequate solution, but it was a little tedious and a little pricey.
Nonetheless it had all sorts of easy integrations like Mailchimp and such that
my Django application could easily use.

Today, with things like Digital Ocean, I wouldn't re-use Heroku for Django
hosting. You also wrote that you'd like to roll your own email server, so I
think that would cut out Heroku completely.

I think you'd be most interested in trying out Digital Ocean for a bit. Start
with a $5 server and [https://www.digitalocean.com/community/tutorials/how-to-
use-...](https://www.digitalocean.com/community/tutorials/how-to-use-the-
django-one-click-install-image) see if it works for you or not. $5 isn't much
to lose on an experiment and if it works for you, you can spin up one of their
other issues

------
prashnts
I'd recommend you keep using Heroku, and use a service such as Mailgun for
emails. The only change you'd need is to add SMTP parameters for
mailgun/whatever in heroku and django config.

If you still want to host your own email server, perhaps setup a Digital Ocean
instance and have the smtp credentials on heroku.

------
tmnvix
I have been very, very happy with Webfaction for about 7 years now. Great
support for Django. Basically everything you could ask for in a shared hosting
solution. $10/m. They also offer non-shared plans from $20/m.

SSH access (even on the shared plan) is the killer feature for me. I also
really appreciate the simplicity of their approach (domains + applications =
websites).

Non-affiliate link: [https://www.webfaction.com/](https://www.webfaction.com/)

Affiliate link:
[https://www.webfaction.com/?aid=34899](https://www.webfaction.com/?aid=34899)

~~~
ylem
I will second this! I have used them for quite some time and their customer
support is extremely responsive! I also like having ssh access.

------
phonon
Amazon Lightsail [1] for Hosting, SES [2] for transactional emails, Workmail
[3] for corporate email (though I'm not sure why your company email has to be
in any way related to your app server.)

[1] [https://amazonlightsail.com/](https://amazonlightsail.com/) [2]
[https://aws.amazon.com/ses/](https://aws.amazon.com/ses/) [3]
[https://aws.amazon.com/workmail/](https://aws.amazon.com/workmail/)

~~~
NetStrikeForce
But Lightsail is not Django hosting...

~~~
phonon
I would not used shared hosting for Django...it's not Wordpress...

~~~
NetStrikeForce
I'm not sure I follow... Op is looking for some Django hosting, doesn't
necessarily have to be shared. It could be containerized or maybe it could be
PaaS (Heroku style).

~~~
phonon
OK, use [https://aws.amazon.com/blogs/aws/new-aws-
codestar/](https://aws.amazon.com/blogs/aws/new-aws-codestar/) and its Django
template.

~~~
NetStrikeForce
Looks very cool, thanks!

------
scardine
I like the guys at Divio[1] (of Django CMS fame). They have a partner program
if you are hosting for your clients.

[1] [https://www.divio.com/en/](https://www.divio.com/en/)

------
0xCMP
Many in the thread have said what I would say: Don't mix your email with the
sending of transactional emails. If you're comfortable with Heroku I recommend
staying there and using something like SES, SendGrid, or Mail Gun to send the
account registration emails.

But, also remember, for most transactional email providers you could allow it
to send as your employees if that is an important part of your needs. That way
you can keep them separate and keep the ability to send email as your
employees.

------
Klasiaster
What about [https://www.openshift.com/](https://www.openshift.com/) – good for
Django, but mail might be a new ground for it?

------
gautamnarula
I've been really happy with Pythonanywhere, a PAAS (basically Heroku, but
exclusively for Python). Pretty cheap, really easy to set up Django right out
of the box, and great customer service (fast responses to emails and forum
posts, even when they're less about the hosting and more about how to do
something in Python or Bash).

My co-founder and I ran our startup on Pythonanywhere and used transactional
email (although we used Mandrill) with no issues.

------
metaphorm
don't use hostgator. discount hosting solutions, in general, are bad fits for
django which kind of takes for granted that you have shell access to the
server and know a little bout of unix sysadmin.

AWS EC2 is a great host but requires you to know how to admin the server a
bit. Heroku is good for small deployments but the budget options don't scale
very well. An AWS competitor like Rackspace or similar might be good too,
especially if you're looking for lower prices.

as for email, get a business account (with custom domain) from gmail or
something similar. you really don't want to be hosting your own email, not
even for a small company. seriously that's a headache you just don't want to
deal with if you don't strictly have to (legal compliance requirements, for
example). it's not like it costs much to use a hosed solution for email.

the django app needs to connect to the email server? why? isn't the whole
point of email that you send messages via SMTP and don't have to have a
server-to-server connection? I think you may have some technical requirements
you need to pin down with more rigor.

------
bastawhiz
I host my Django app on Heroku and use Amazon SES to send email. On Amazon, I
use WorkMail, which is built on top of SES and works seamlessly with it.

------
mozumder
Call up your ISP and ask for a business account with static-IP address. I use
a server on a static IP address from my Verizon FIOS ISP.

I get to run any size Django web server I want, and built a custom server for
around $2000, and I get to host my own email server as well. I use a Mac Mini
server to get the mail server running. Quite easy.

------
sumodirjo
I use webfaction to host multiple wordpress sites and so far the performance
and support is good. it support python / Django hosting

For email I think it's better to use email service like google apps, office
365, zoho mail or fastmail.

For account registration emails, it's better to use transactional email
service like sendgrid, mandrill, mailgun, mailjet, or postmark.

------
pasbesoin
Another voice for separating the two to separate servers -- separate hosting
providers, even, if that ends up making sense.

------
owenconti
$5/month droplets with Digital Ocean would be my vote. You have the freedom to
use whatever email server you want.

------
CameronBanga
We've used Digital Ocean to host Django projects for years, with no issue!

------
iansowinski
I am happy with cheap VPS from ovh

