Controversial plans to build a US-style mega pig-farm in South Derbyshire close to a prison and residential housing pose serious health risks to those living and working there and could breach their legal rights to protection of their private and family life, the local council is being warned.

In the light of fresh legal advice, the organic farmers' group, the Soil Association and Friends of the Earth have joined forces with local group Foston Community Forum and Pig Business, film-makers and campaigners, to urge Derbyshire county council to refuse planning permission for the proposed development at Foston.

Their challenge – the first against the scheme under the Human Rights Act – is set out in a joint letter to the county council, stating that "planning authorities … have an obligation under the Human Rights Act 1998 to consider the effects of their decision on the human rights of affected third parties. The right to private and family life prevents not just physical incursions into the home or residence, but also interference from things such as noise, smell, emissions."

It goes on to say that the prison staff cannot avoid working close to the proposed development unless they resign from the jobs. The inmates of Foston Hall prison are not living in the area by choice, and clearly do not have the option of moving away if the development goes ahead. They will not be able to escape the risk to their health posed by the development, and the letter warns that allowing the pig factory to go ahead could also breach the inmates' right to be protected from inhumane treatment.

Midland Pig Producers (MPP) has applied for permission to build the farm – which could house up to 25,000 animals – on a greenfield site west of the historic village of Foston and adjoining a women's closed prison which houses up to 290 prisoners. If approved, it would become the third largest factory farm in the UK, sending more than 1,000 pigs to slaughter every week.

The legal letter also cites new research which shows that intensive pig factories of this kind can adversely affect the health of nearby residents. This has been confirmed by the government's Health Protection Agency (HPA), which says that those living within 150 metres of intensive pig farms "could be exposed to mutli-drug resistant organisms". The proposed development will be built within 150m of HMP Foston Hall - as well as within 75m of the nearest properties being planned for workers at the development site.

After an application for a mega-dairy in Lincolnshire by Nocton Dairies, which was later shelved, Foston has become the focus of a fierce fight over opposing visions for British farming. The Soil Association's concerns have been mainly about disease, antibiotic resistance and animal welfare in large pig herds.

Peter Melchett, policy director of the Soil Association, said: "The objections to the pig factory at Foston are mounting all the time, because of the growing weight of new scientific evidence of real risks to the health of local people, and to the staff and inmates of the prison right next door to the proposed site. Now it seems that the legal rights of local people may also be infringed by the proposed development."

Victoria Martindale, representative of the Foston community forum, said: "As a medical professional I am concerned about the health risks that this proposal will bring to local residents. Those living in the closest vicinity to the proposed site include the most susceptible and at risk groups such as children, the elderly and individuals already with known respiratory and other diseases. It is not fair to expect the residents of Foston to go about their everyday lives while being forced to continuously breathe in air that will put their and their families' health at risk."

A Derbyshire county council spokesperson said: "We have had thousands of views during the consultation and have had to look at and consider them. Following this, we have sent out for additional information from some agencies and are awaiting that. When this comes in we shall have to consider this and ensure we have all the information we need before compiling the report for the committee to consider."

MPP was contacted by the Guardian but has not issued a response to the letter.

• An MPP spokeswoman provided the following response after this article was published: "Once again, the situation is being distorted. While we have never expected people who don't eat meat to support our plans, we have repeatedly suggested that reading the information contained within the planning application will help to calm concerns. In our view there isn't any undue risk to local residents, including residents of HMP Foston. Disease is controlled by good standards of hygiene, welfare and management systems, not size. As the plans show, the entire farm will be a high health unit operating to the highest levels of bio-security to minimise the risk of disease entering the farm or indeed leaving it."