Ask HN: Smallest laptop that is decent for coding?

52 points by krm01 ↗ HN
I'm looking for something as small as possible but can still be used in a decent way for coding. The goal isn't to code super complex things but use it more as a tool to quickly write tiny JS/PHP/Html programs. The small form factor is important so I can keep it with me like you would keep a physical paper notebook with you

165 comments

[ 2.0 ms ] story [ 236 ms ] thread
Anything with SSD and 8-16GB RAM should do the work. Personally i would buy a 13" macbook pro.
Do not buy a 13 inch MBP! The keyboard still hasn't been upgraded to the "good" version on that. The 16-inch macbook pro and the macbook air it.
I have a 15 inch MBP with the dodgy keyboard, but it's bearable and 95% of the time I use an external Apple keyboard and a 4K screen.
if you are looking at Macs, mac book air.

Chromebook is a fantastic option in terms of price, though everything may have to stay in the cloud.

macbook air, is no good for programming. sketching and frontend things yes, but when you start running environments within it like docker for example. it will crash.
If you spec it out to about 2000$, with the i7 upgrade, 16 GB of RAM, 1TB SSD, I'm pretty sure it will be plenty powerful for the majority of developers. Probably as good as the 5 year old MacBook Pro everyone still uses.

Bonus: you get a function key row

You don't need to run docker for every single thing
Yes, you don't need Docker for the development environment. I do that sometimes though for convenience and for projects that I develop on only now and then.
The use-case is “quickly write tiny JS/PHP/Html programs”. I do that on my Air. I have never used docker and don’t really know what docker is besides a tech-de-jour.
JS means using npm and node, ive heard my laptop fans go crazy at times. I'm MBP 13 inch, i7, SSD, 16GB Ram
That's not really true though, and I know this from personal experience in the company that I work for.

We have a fairly large development team all using MacBook Air, the previous version. It's a little workhorse, but you gotta know its limitations.

It struggles a little with Java development (i.e. running NetBeans or IntelliJ), but the new version (i.e. 2019 model) will do that just fine.

Depends on the environment. You can easily run Docker containers on the new Air.
I've not tried it, but I think you can install Ubuntu within a container on a Chromebook[1] without jailbreaking or removing ChromeOS.

[1] https://ubuntu.com/tutorials/install-ubuntu-on-chromebook

No it’s even easier and better than that. There is a built in Linux container internally called crostini, you just turn it on and it’s a fully featured Linux install with admin privileges and a terminal.
You can repave a lot of Chromebooks with Linux, and should, if you're using one as a dev machine.
The lack of one modifier key left of the keyboard is an issue to me. Equivalent Windows laptops cost about the same and have an extra key.

And can run Linux just fine.

Caps Lock is useless. Map it to Control and the search key to Super, and you have all the modifiers you need, and in a more comfortable configuration besides.
That's still one key short.
What do you use hyper for? It's cool that DEs support binding it, but I've never found a use.
I use Emacs. I have use for as many keys as I can add to a keyboard (on my desk I have a PC 122 model M by Unicomp)
I mean, I do too, have for over a decade now. I'm still much more likely to bind under a prefix than directly to a meta chord.
I managed to get my hands on a Lenovo X280 before they were discontinued. I think it's fantastic and really hits the sweet spot between weight and performance - it's my main driver and weightwise I have a hard time telling it apart from my iPad Pro 11 with a keyboard case.
I love my ASUS ZenBook 13!

  * The best laptop keyboard I've ever typed on!
  * Great screen
  * Weights 1 kg
  * Solid 8 hours of work on battery
>The best laptop keyboard I've ever typed on!

Will definitely check that out just to see the keyboard. Getting really fed up with all the new Apple's keyboard design / experiences.

they went back to scissor from butterfly...
But at reduced Key Travel. The new scissor may be more reliable ( we dont have data yet ), but it certainly isn't the old scissors. It doesn't feel anything like it, in fact even with 1mm key travel, 0.3 more than the 0.7mm butterfly, it still felt very "butterfly" to me.
Bummer. The keyboard feels near as close to perfect for me. I just don’t have the 2k to get the laptop that I want right now.
Do you use windows or linux ? If so, which distribution ?
Windows 10 with Ubuntu 18.04 on VirtualBox
I use popOS on the UX330UN, not the exact same model, but fairly similar. I haven't had very many major issues with pop, but it is the only distro that hasn't given me any.
12" MacBook with the i5 or i7 (it's rare now, though). I've made do with the m3 version and while PHPStorm runs slow, it's bearable.
If you REALLY value compactness, the smallest nice computer you can get is probably the discontinued 12-inch macbook. It really is amazingly small. It is underpowered but "quickly write tiny JS/PHP/Html programs" is about the least demanding thing you can do, work wise, so I think it would be fine.

It's a sacrifice for compactness though. It also has the "bad" keyboard, though some people don't mind.

The just released macbook air is probably an all around good choice though.

I spent the last few years using one of these as my mobile development solution. I still use it for scala development - not too underpowered for this.

I feel I have been lucky with the keyboard, no real stuck keys and the keyboard doesn't feel cramped. And it slips into a small bag very easily.

I have replaced the screen once, when I dropped something on it and the battery, which is expensive. The bad thing about this form factor is how every small issue is back-to-workshop.

I love mine, going to get another one. Actually maybe I should the air or the pro just to see.
I’m using one as my daily driver for years now and I can definitely recommend it. It’s been more than enough to work on sane projects like a web app with a DB server running. Of course don’t expect to run Kubernetes with dozens of microservices on it. Mobile development can be a challenge though - Xcode is very resource-hungry.
Two words: MacBook Air.

You can't go wrong with that little workhorse. The new one (high spec) will even do Java development just fine and run two 4K screens.

Not small or light any longer, since they killed the 11" model.
Actually, while indeed heavier, I was surprised that my 2018 13" fit in the sleeve of my older 11" MBA. A bit snug, but the screen width seems to have expanded inside the frame. And yes, while the widths are fairly similar, the depths are not.
I've used a fully loaded MacBook and it works well. It's quite slow compared to a desktop but it's fast enough and has the Retina screen. This laptop is basically a tablet in laptop form factor; it is ultra tiny and very nice to use from a physicality standpoint.

I'm currently using an X1 Carbon ThinkPad Gen 4 with a 4K screen and it is pretty nice too. It's a step up both performance wise and size wise from the MacBook.

The new Dell XPS 2020 or the MB Air.
12" Macbook would probably be optimal.

Surface Go is an option to consider, however it can't really be used on a lap.

Any tablet + x2go or apache guacamole
MacOS: check out the latest MacBook Air 13", the one just released - it has a new keyboard, better base disk configuration and it's cheaper than before.

Windows: Dell XPS 13 has been the go-to laptop for years, they keep refreshing it, so make sure to get at least the 2019 model (which has a camera on the top of the screen, not the bottom), or ideally the 2020 model, which features a new keyboard and even smaller bezels (and a new, 16:10 screen).

Windows runner up: look at Surface Pro 7 (x86) and Pro X (ARM), if the form factor, performance and ergonomics fit your needs, they might be preferable to the XPS 13. The Pro X is quite a wild card, since the compatibility is not quite there yet, but it's closer to a paper notebook than laptops or even the Pro 7.

I would advise against anything smaller than 13", because it will be fairly suboptimal to type on.

Oof! 16:10 display in a 13" chassis is tough to beat. Those extra vertical pixels make coding on it that much nicer. Way to go Dell! If only I could get 16:10 in a ThinkPad; I'm a sucker for their keyboards and trackpoint.
Yeah that aspect ratio change is huge.

Honestly, it's way overdue. The widescreen style laptop has some uses ... but it really is a pain for so many things.

The MacBook is 16:10 to, which I found very nice.
This is a great list but if they want something smaller than a 13 inch, I would add the surface go too. Seems like what they are asking for.
The Surface Go is an amazing device for work on the... go, but the ergonomics of the display and cramped keyboard make it suboptimal for any longer period of time (be it a coffee shop, your bed or anything like that).

If you plan to work only at your desk, where you connect it to an external display (USB-C, ideally, to get both power and video) and external keyboard and only use it as a tablet otherwise, then sure, it would work well. But using it as a standalone machine would be rather inconvenient.

I've used it as such for extended periods of time during a long working holiday. Not ideal but it worked well enough, and the form factor is very portable indeed. The screen cover keyboard is a must though.
12" MacBook is quite a bit smaller than the 13" Macs.
True, but it's also quite a bit more discontinued :(
I carry a 12" in this role and it's great. Surprisingly long battery life, weighs nothing and, assuming you spend most of your time in an editor, fast enough.

Downsides are (a) butterfly keyboard and (b) tiny screen. If you do anything that requires compilation, get something with a CPU fan like the new 13" Air.

Get the 16GB model either way.

I loved mine (the original 12"), keyboard and all. Kept it with me all the time in a little sling bag... like a gun in holster. BANG! BANG!

Rocked it til it broke, and I'm still missing it 3 years later. I guess I need a new one.

Hah. I'm trying to find a non-dorky way to clip it to my belt. It's my "hey I gotta go to a meeting and take notes but I don't want to mess up my desktop" laptop.
Also I killed 2 via running Jetbeans. (Client requirement not my choice...)
I am currently typing this on my mid-2013 11" Macbook Air and it's still going strong. It's too bad that Apple is not making anymore 11" laptops anymore because I think it's exactly what OP wants. I had the same exact criteria when looking for a laptop and I work with similar technologies, but I've also done Android/Kotlin (using Android Studio) and C#/.NET (using full Visual Studio) with this laptop without any problems. I also play games via Steam (mostly indie games, not big AAA ones) on it. I have a bag¹ (side bag/satchel) that it fits perfectly into and makes it easy to carry around. It's been great taking this on vacation with me, super light.

I am looking to upgrade though and the new 2020 Air does look good but with the modifications I want brings the price close to $1699 and I'm not ready to spend that yet

¹ https://www.scaramangashop.co.uk/mini-leather-satchel-11-inc... <-- bought it from this company but they don't make my exact bag anymore, but this is the closest except mine is the "portrait mode" of this

edit: Forgot to add that I've also used Xcode on this in the past but I am not on Catalina yet so I have not touched Xcode in a while.

Dell makes garbage compared to Lenovo. Why not get an x390/x13 with that delicious keyboard?
bezels? it's not just aesthetics; thin bezels is a pretty important feature on an ultraportable imo, maximizes screen real estate for the space it takes up in your bag.
What? No.

They are already ultraportables. Once they are that small as a class of computer reliability and quality becomes important.

God help you with support and returns if something goes wrong with your dell. I’ve been there before and it’s hell on earth.

+1, 2013 11" MacBook Air is still going strong! I need to be a little vigilant about not too many Chrome tabs to keep it from getting too sluggish, but it's excellent for coding, Gmail, Google Docs, video chat, Netflix.
I did most of my PhD on that machine, including tons of coding. With a nice window manager, it's doable. A higher resolution 16:10 screen would improve the experience, though.

It was Linus Torvalds daily driver for some time. I also wiped out OS X and went with Linux, deployed directly as an EFISTUB so no bootloader. Being all-Intel, sans a mediocre Broadcom wireless card, the machine had perfect Linux compatibility.

The $100 core i5 upgrade on the latest Macbook Air in particular. It's a big bang for buck (especially by Apple standards) since it goes from 2 cores to 4 and adds boost clock headroom.
What about the $250 upgrade for i7 - worth it for $150 more than the i5? I'm going to be getting it and I want to have it for 4-5 years as I have with the 2015 MBA, getting the better processor seems like a decent future-proofing.

I mostly develop in Python and Go, but I do want to get into Rust and I understand the compilation is demanding.

I would say not worth it. Very minimal ghz boost you probably won't notice and an additional 2MB (6->8mb) of L3 processor cache you probably won't notice.
I haven't seen any benchmarks, but I doubt you'll get a big return going to the i7, certainly nowhere near the return on investment the dual core i3 to quad core i5 is. Macbook air is mostly going to thermally limited under sustained load anyway, so the i7 benefits are likely pretty limited.
Thinkpad X2xx - 12", very reliable, coreboot-able, excellent keyboard.
second that, though now they converted to 13" and last model became x390 (x270, x280, x390). pay attention to ram amount. it is soldered in the last model, and, not upgradable)
I'm still loving my 2013 MacBook Air 13" with an i7 and 8 GB RAM.

I mostly do Python development with Vim (web, DevOps, ML/NLP) and Dart/Flutter stuff with VSCode. For bigger workloads I ssh into my iMac.

iPad Pro 11"?

I mean there aren't that many "small" laptop, just reading between the line of your needs.

Today most laptop starts at 13". I am not sure if that fit your definition of Small. But the new MacBook Air is pretty decently priced for an Apple product.

I own two iPads, and I really don't think it is there yet in terms of writing any serious code.
I have a MacBook Pro 15", which is too big and actually pretty much resent and hate.

an iPad Pro 11" which I absolutely love, but is abysmal and no where near any good for coding on.

And currently eyeing that MacBook Air with a massive 2TB, 16GB, and i7 option for still less than the lowest end 16" MacBook Pro and just barely more than the stock 13" high end MacBook Pro.

Dell Latitude 7390: it's basically a better XPS13.

Same size, same small bazel, weighs meaybe 100g more, but has all of the ports you could need and ram, disk and battery are easily replaceable. Probably has better thermals too, since less compromises were done in head dissipation.

I can't really understand why people are buying the XPS13 when the Latitude 7390 is available (probably for less money).

<edit> the size is 13", basically the size of an A4 sheet of paper. My 7390 from work is equipped with an 8th gen i7 (4c8t) and 16gb ram and an nvme add, more than enough to do most things. Lower end models exist too of course. </edit>

If youre looking for something on the cheap, probably an used thinkpad will do: X or T series, 40-50-60 series (X2[456]0, T4[456]0)

I own a Samsung Chromebook 3 with GalliumOS, it has 4Gb of RAM and it pretty fast thanks to that lightweight Debian distro.
JS/PHP can pretty much run on everything from 2018+. When adding Docker or NPM and some non-interpreted compilation involved that's where machine's power shines.

Pretty much any 8th gen / 10th gen ulta-low-voltage quad core would be more than sufficient.

As suggest, If you'd like the lockdown. the 2020 MacBook Air is finally an Apple machine balancing it all for developers.

The Lenovo Carbon X1 is also a power machine.

Main advantage choosing non-Mac machine is ability to replace key components. Most PCs even the slimmest, allow replacing at least the NVMe so you could get even 2TB for ~200$.

Smallest size you could go imho is 12". but keyboard is the 2nd key factor for a dev I guess.

I have tried many, believe me. First thing, if it has glossy screen I would quickly discard it - your vision health is worth much more than a pretty picture in Facebook. Having said this, I would go for dell XPS family. They are not cheap but they are very robust. In addition, screen border is almost nonexistent so all it's size is for your screen. Very good Linux support (there is a a version that ships with Ubuntu). Keyboard is fantastic and the combination of carbon fiber with aluminium works great, in my opinion. Give it a try.
Recently I ordered a matte screen protector for my MacBook Pro, and it works really well. I would not immediately write off all laptops with glossy screens.

(Note I don't have a recommendation for a particular screen protector, I used a local supplier in my tiny little European country).

Glad to know people can now work with glossy screens. It still seems a workaround to emulate what I consider a must, though.
Seconded. I use one on my Surface Pro 6 and it makes it a substantially more versatile system.
I love my XPS 13 and have written a fair bit of code on it in various circumstances. It's small enough to use during takeoff and landing and the battery life is enough to last a full day. No numpad but otherwise full sized keyboard.
I would add: matte, IPS screen. The latter cannot be fixed with a screen shield.

+1 for Linux support on Dell's laptops. Usually everything works straight after installation, contrary to Lenovo and HP. I do not recommend HP hardware at all BTW.

OpenPandora, the Pyra would be better but not readily available immediately. Fit in pocket easily, keys might be a tad too small for you? Another pocket sized device is GPD Win, which I believe you can install Linux onto the first version. Just some options, leaning more on the small form factor side/.