Nanoparticles (NPs) have been experimentally found to either promote or inhibit amyloid aggregation of proteins, but the molecular mechanisms for such complex behaviors remain unknown. Using coarse-grained molecular dynamics simulations, we investigated the effects of varying the strength of nonspecific NP-protein attraction on amyloid aggregation of a model protein, the amyloid-beta peptide implicated in Alzheimer's disease. Specifically, with increasing NP-peptide attraction, amyloid aggregation on the NP surface was initially promoted due to increased local protein concentration on the surface and destabilization of the folded state. However, further increase of NP-peptide attraction decreased the stability of amyloid fibrils and reduced their lateral diffusion on the NP surface necessary for peptide conformational changes and self-association, thus prohibiting amyloid aggregation. Moreover, we found that the relative concentration between protein and NPs also played an important role in amyloid aggregation. With a high NP/protein ratio, NPs that intrinsically promote protein aggregation may display an inhibitive effect by depleting the proteins in solution while having a low concentration of the proteins on each NP's surface. Our coarse-grained molecular dynamics simulation study offers a molecular mechanism for delineating the contrasting and seemingly conflicting effects of NP-protein attraction on amyloid aggregation and highlights the potential of tailoring anti-aggregation nanomedicine against amyloid diseases.