Four months ago I built a sign up form for a small gym near my house. It was my first paid freelance job, 6,000 rupees, and I spent two weeks on it. Animations, a progress bar, fields that turned red while you typed. It worked on every phone I owned.
The owner looked at it for about a minute. He said it was lovely, but why does it ask for date of birth and home address? All he needed was a name, a phone number and which batch, morning or evening. I had copied the fields from a big gym website because I thought that's what a gym form looks like. I never asked him what he does with the information.
So I cut it down to three fields. Then he said people forget the batch timings, so I put the timings under the field. Then he said the front desk staff need to see new sign ups in the morning without logging in anywhere, so I made a plain page they can open on a phone. That third version took two days, not two weeks.
What I got wrong wasn't really the code. I thought my job was just to build the thing. Half of it is sitting next to the person for fifteen minutes and watching how they work. Now before I open my editor I ask what happens before this screen, what happens after it, and who gets annoyed when it breaks. It has saved me a lot of rewriting, and he has given me two more small jobs since.
Did anyone else build the wrong thing first on their early freelance work? What do you ask a client now before you start?