GitLab is open source. You can run in on almost anything or use our free cloud offering GitLab.com.
We're almost at feature parity with GitHub, but also offer other things. For instance features such as rebase before merge, merge request approvals, LDAP group integration.
In addition, we build GitLab Continuous Integration, which is a fully featured CI tool that is easy to scale and integrates with GitLab. It's completely free.
See more here: https://about.gitlab.com/better-than-github/
They also offer a hosted version too that's free depending on your usage.
Much of this can be replicated in those services though it may require a slightly more manual integration.