Accommodation

Where to find apartments
It's common to use agents to help you find somewhere to live in the city. It's important to be specific about your requirements but even then, you will often be shown properties that do not meet your requirements and it's best to be honest and tell them if it's not what you're looking for rather than accept somewhere you aren't completely happy with. Sometimes, they will deliberately show you some of the poorer quality properties in the hope you may accept one of them.
There are also a few apps and websites for apartment searching such as SmartShanghai which has a housing section.
Typical Rental Terms
Rent is usually paid monthly, with a one or two-month deposit. This means you will probably need to prepare to pay 3 months' rent upfront. I highly recommend trying to minimise the deposit amount, even if it means paying say, two months' rent in advance, because landlords ofteh try their best to avoid returning deposits. If you've only paid one month's deposit, that's the most you can lose in such situations. Where the rental amount is low, it is sometimes required to pay 6 months in advance but this is more common with local tenants with rents of just a few thousand RMB per month.
Commission is usually paid by the landlord, but agents do sometimes require the tenant to also pay a part of the commision (eg 50% of one month's rent). This should be clarified at the beginning to avoid disputes later.